aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorclaziss <claziss@synopsys.com>2018-08-06 16:41:32 +0300
committerClaudiu Zissulescu <claziss@gmail.com>2018-08-06 16:41:32 +0300
commitb6523c37fb52fc38da6e152328341caffd793749 (patch)
treed6cc3d850d873fa47a4962079343d98a30a7242d /gas
parent821a26825bdcb96358a51f5c2140475951429470 (diff)
downloadgdb-b6523c37fb52fc38da6e152328341caffd793749.zip
gdb-b6523c37fb52fc38da6e152328341caffd793749.tar.gz
gdb-b6523c37fb52fc38da6e152328341caffd793749.tar.bz2
[ARC] Update handling AUX-registers.
Update aux-registers data-base, and accept aux-registers names with upper/lowercase names. opcode/ 2017-07-18 Claudiu Zissulescu <claziss@synopsys.com> * arc-regs.h: Update aux-registers. gas/ 2017-07-18 Claudiu Zissulescu <claziss@synopsys.com> * config/tc-arc.c (find_opcode_match): Accept uppercase aux-regs names. * testsuite/gas/arc/ld2.d: Update test. * testsuite/gas/arc/taux.d: Likewise. * testsuite/gas/arc/taux.s: Likewise. include/ 2017-07-18 Claudiu Zissulescu <claziss@synopsys.com> * opcode/arc.h (ARC_OPCODE_ARCV1): Define.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog8
-rw-r--r--gas/config/tc-arc.c10
-rw-r--r--gas/testsuite/gas/arc/ld2.d2
-rw-r--r--gas/testsuite/gas/arc/taux.d10
-rw-r--r--gas/testsuite/gas/arc/taux.s157
5 files changed, 18 insertions, 169 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index ccee98e..a97edcd 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,11 @@
+2018-08-06 Claudiu Zissulescu <claziss@synopsys.com>
+
+ * config/tc-arc.c (find_opcode_match): Accept uppercase aux-regs
+ names.
+ * testsuite/gas/arc/ld2.d: Update test.
+ * testsuite/gas/arc/taux.d: Likewise.
+ * testsuite/gas/arc/taux.s: Likewise.
+
2018-08-06 Jan Beulich <jbeulich@suse.com>
* config/tc-i386.c (build_modrm_byte): Use RegIP and RegIZ.
diff --git a/gas/config/tc-arc.c b/gas/config/tc-arc.c
index a1ce34d..3fc907a 100644
--- a/gas/config/tc-arc.c
+++ b/gas/config/tc-arc.c
@@ -1882,13 +1882,20 @@ find_opcode_match (const struct arc_opcode_hash_entry *entry,
case O_symbol:
{
const char *p;
+ char *tmpp, *pp;
const struct arc_aux_reg *auxr;
if (opcode->insn_class != AUXREG)
goto de_fault;
p = S_GET_NAME (tok[tokidx].X_add_symbol);
- auxr = hash_find (arc_aux_hash, p);
+ /* For compatibility reasons, an aux register can
+ be spelled with upper or lower case
+ letters. */
+ tmpp = strdup (p);
+ for (pp = tmpp; *pp; ++pp) *pp = TOLOWER (*pp);
+
+ auxr = hash_find (arc_aux_hash, tmpp);
if (auxr)
{
/* We modify the token array here, safe in the
@@ -1899,6 +1906,7 @@ find_opcode_match (const struct arc_opcode_hash_entry *entry,
tok[tokidx].X_add_number = auxr->address;
ARC_SET_FLAG (tok[tokidx].X_add_symbol, ARC_FLAG_AUX);
}
+ free (tmpp);
if (tok[tokidx].X_op != O_constant)
goto de_fault;
diff --git a/gas/testsuite/gas/arc/ld2.d b/gas/testsuite/gas/arc/ld2.d
index 0a7874c..f7237e7 100644
--- a/gas/testsuite/gas/arc/ld2.d
+++ b/gas/testsuite/gas/arc/ld2.d
@@ -15,5 +15,5 @@ Disassembly of section .text:
1c: 130f 0082 ldb r2,\[r3,15\]
20: 14fe 8103 ld[hw]+ r3,\[r4,-2\]
24: 212a 0080 lr r1,\[r2\]
- 28: 216a 0500 lr r1,\[dmc_code_ram\]
+ 28: 216a 0500 lr r1,\[0x14\]
2c: 206a 0000 lr r0,\[status\]
diff --git a/gas/testsuite/gas/arc/taux.d b/gas/testsuite/gas/arc/taux.d
index 6303146..6759d73 100644
--- a/gas/testsuite/gas/arc/taux.d
+++ b/gas/testsuite/gas/arc/taux.d
@@ -3,9 +3,6 @@
#source: taux.s
# Most of the AUX rgisters are defined for all ARC variants besides the
# FPX/FPUDA registers which should end as undefined when assemble generic.
-.* U arc600_build_config
-.* U aux_crc_mode
-.* U aux_crc_poly
.* U aux_dpfp1h
.* U aux_dpfp1l
.* U aux_dpfp2h
@@ -16,11 +13,4 @@
.* U d2l
.* U dpfp_status
.* U fp_status
-.* U jli_base
-.* mx0
-.* mx1
-.* my0
-.* my1
-.* scratch_a
-.* tsch
#pass
diff --git a/gas/testsuite/gas/arc/taux.s b/gas/testsuite/gas/arc/taux.s
index 57e2cf3..a2a9fcf 100644
--- a/gas/testsuite/gas/arc/taux.s
+++ b/gas/testsuite/gas/arc/taux.s
@@ -1,86 +1,24 @@
- lr r5, [status]
- lr r5, [semaphore]
lr r5, [lp_start]
lr r5, [lp_end]
lr r5, [identity]
lr r5, [debug]
lr r5, [pc]
- lr r5, [adcr]
- lr r5, [apcr]
- lr r5, [acr]
lr r5, [status32]
- lr r5, [status32_l1]
- lr r5, [status32_l2]
- lr r5, [bpu_flush]
- lr r5, [ivic]
lr r5, [ic_ivic]
- lr r5, [che_mode]
lr r5, [ic_ctrl]
- lr r5, [mulhi]
- lr r5, [lockline]
- lr r5, [ic_lil]
- lr r5, [dmc_code_ram]
- lr r5, [tag_addr_mask]
- lr r5, [tag_data_mask]
- lr r5, [line_length_mask]
- lr r5, [aux_ldst_ram]
- lr r5, [aux_dccm]
- lr r5, [unlockline]
lr r5, [ic_ivil]
lr r5, [ic_ram_address]
lr r5, [ic_tag]
lr r5, [ic_wp]
lr r5, [ic_data]
- lr r5, [sram_seq]
lr r5, [count0]
lr r5, [control0]
lr r5, [limit0]
- lr r5, [pcport]
- lr r5, [int_vector_base]
- lr r5, [aux_vbfdw_mode]
- lr r5, [jli_base]
- lr r5, [aux_vbfdw_bm0]
- lr r5, [aux_vbfdw_bm1]
- lr r5, [aux_vbfdw_accu]
- lr r5, [aux_vbfdw_ofst]
- lr r5, [aux_vbfdw_intstat]
- lr r5, [aux_xmac0_24]
- lr r5, [aux_xmac1_24]
- lr r5, [aux_xmac2_24]
- lr r5, [aux_fbf_store_16]
- lr r5, [ax0]
- lr r5, [ax1]
- lr r5, [aux_crc_poly]
- lr r5, [aux_crc_mode]
- lr r5, [mx0]
- lr r5, [mx1]
- lr r5, [my0]
- lr r5, [my1]
- lr r5, [xyconfig]
- lr r5, [scratch_a]
- lr r5, [burstsys]
- lr r5, [tsch]
- lr r5, [burstxym]
- lr r5, [burstsz]
- lr r5, [burstval]
- lr r5, [xtp_newval]
- lr r5, [aux_macmode]
- lr r5, [lsp_newval]
- lr r5, [aux_irq_lv12]
- lr r5, [aux_xmac0]
- lr r5, [aux_xmac1]
- lr r5, [aux_xmac2]
lr r5, [dc_ivdc]
lr r5, [dc_ctrl]
lr r5, [dc_ldl]
lr r5, [dc_ivdl]
lr r5, [dc_flsh]
- lr r5, [dc_fldl]
- lr r5, [hexdata]
- lr r5, [hexctrl]
- lr r5, [led]
- lr r5, [dilstat]
- lr r5, [swstat]
lr r5, [dc_ram_addr]
lr r5, [dc_tag]
lr r5, [dc_wp]
@@ -100,7 +38,6 @@
lr r5, [mpu_build]
lr r5, [rf_build]
lr r5, [mmu_build]
- lr r5, [aa2_build]
lr r5, [vecbase_build]
lr r5, [d_cache_build]
lr r5, [madi_build]
@@ -163,7 +100,6 @@
lr r5, [se_dbg_data3]
lr r5, [se_watch]
lr r5, [bpu_build]
- lr r5, [arc600_build_config]
lr r5, [isa_config]
lr r5, [hwp_build]
lr r5, [pct_build]
@@ -181,21 +117,7 @@
lr r5, [control1]
lr r5, [limit1]
lr r5, [timer_xx]
- lr r5, [arcangel_periph_xx]
- lr r5, [periph_xx]
- lr r5, [aux_irq_lev]
lr r5, [aux_irq_hint]
- lr r5, [aux_inter_core_interrupt]
- lr r5, [aes_aux_0]
- lr r5, [aes_aux_1]
- lr r5, [aes_aux_2]
- lr r5, [aes_crypt_mode]
- lr r5, [aes_auxs]
- lr r5, [aes_auxi]
- lr r5, [aes_aux_3]
- lr r5, [aes_aux_4]
- lr r5, [arith_ctl_aux]
- lr r5, [des_aux]
lr r5, [ap_amv0]
lr r5, [ap_amm0]
lr r5, [ap_ac0]
@@ -220,8 +142,6 @@
lr r5, [ap_amv7]
lr r5, [ap_amm7]
lr r5, [ap_ac7]
- lr r5, [pct_control]
- lr r5, [pct_bank]
lr r5, [fp_status]
lr r5, [aux_dpfp1l]
lr r5, [d1l]
@@ -236,17 +156,11 @@
lr r5, [d2l]
lr r5, [dpfp_status]
lr r5, [d2h]
- lr r5, [rtt]
lr r5, [eret]
lr r5, [erbta]
lr r5, [erstatus]
lr r5, [ecr]
lr r5, [efa]
- lr r5, [tlbpd0]
- lr r5, [tlbpd1]
- lr r5, [tlbindex]
- lr r5, [tlbcommand]
- lr r5, [pid]
lr r5, [mpuen]
lr r5, [icause1]
lr r5, [icause2]
@@ -254,11 +168,8 @@
lr r5, [aux_itrigger]
lr r5, [xpu]
lr r5, [bta]
- lr r5, [bta_l1]
- lr r5, [bta_l2]
lr r5, [aux_irq_pulse_cancel]
lr r5, [aux_irq_pending]
- lr r5, [scratch_data0]
lr r5, [mpuic]
lr r5, [mpufa]
lr r5, [mpurdb0]
@@ -293,71 +204,3 @@
lr r5, [mpurdp14]
lr r5, [mpurdb15]
lr r5, [mpurdp15]
- lr r5, [eia_flags]
- lr r5, [pm_status]
- lr r5, [wake]
- lr r5, [dvfs_performance]
- lr r5, [pwr_ctrl]
- lr r5, [aux_vlc_buf_idx]
- lr r5, [aux_vlc_read_buf]
- lr r5, [aux_vlc_valid_bits]
- lr r5, [aux_vlc_buf_in]
- lr r5, [aux_vlc_buf_free]
- lr r5, [aux_vlc_ibuf_status]
- lr r5, [aux_vlc_setup]
- lr r5, [aux_vlc_bits]
- lr r5, [aux_vlc_table]
- lr r5, [aux_vlc_get_symbol]
- lr r5, [aux_vlc_read_symbol]
- lr r5, [aux_ucavlc_setup]
- lr r5, [aux_ucavlc_state]
- lr r5, [aux_cavlc_zero_left]
- lr r5, [aux_uvlc_i_state]
- lr r5, [aux_vlc_dma_ptr]
- lr r5, [aux_vlc_dma_end]
- lr r5, [aux_vlc_dma_esc]
- lr r5, [aux_vlc_dma_ctrl]
- lr r5, [aux_vlc_get_0bit]
- lr r5, [aux_vlc_get_1bit]
- lr r5, [aux_vlc_get_2bit]
- lr r5, [aux_vlc_get_3bit]
- lr r5, [aux_vlc_get_4bit]
- lr r5, [aux_vlc_get_5bit]
- lr r5, [aux_vlc_get_6bit]
- lr r5, [aux_vlc_get_7bit]
- lr r5, [aux_vlc_get_8bit]
- lr r5, [aux_vlc_get_9bit]
- lr r5, [aux_vlc_get_10bit]
- lr r5, [aux_vlc_get_11bit]
- lr r5, [aux_vlc_get_12bit]
- lr r5, [aux_vlc_get_13bit]
- lr r5, [aux_vlc_get_14bit]
- lr r5, [aux_vlc_get_15bit]
- lr r5, [aux_vlc_get_16bit]
- lr r5, [aux_vlc_get_17bit]
- lr r5, [aux_vlc_get_18bit]
- lr r5, [aux_vlc_get_19bit]
- lr r5, [aux_vlc_get_20bit]
- lr r5, [aux_vlc_get_21bit]
- lr r5, [aux_vlc_get_22bit]
- lr r5, [aux_vlc_get_23bit]
- lr r5, [aux_vlc_get_24bit]
- lr r5, [aux_vlc_get_25bit]
- lr r5, [aux_vlc_get_26bit]
- lr r5, [aux_vlc_get_27bit]
- lr r5, [aux_vlc_get_28bit]
- lr r5, [aux_vlc_get_29bit]
- lr r5, [aux_vlc_get_30bit]
- lr r5, [aux_vlc_get_31bit]
- lr r5, [aux_cabac_ctrl]
- lr r5, [aux_cabac_ctx_state]
- lr r5, [aux_cabac_cod_param]
- lr r5, [aux_cabac_misc0]
- lr r5, [aux_cabac_misc1]
- lr r5, [aux_cabac_misc2]
- lr r5, [arc600_build_config]
- lr r5, [smart_control]
- lr r5, [smart_data_0]
- lr r5, [smart_data_1]
- lr r5, [smart_data_2]
- lr r5, [smart_data_3]