proc sim_has_rv_and_cris {} {
global srcdir
global subdir
- global global_as_options
global global_ld_options
global global_sim_options
# what we want to do it to run the simulator without affecting the
# PASS/FAIL counters, and we can use e.g. run_sim_test for that.
- if ![info exists global_as_options] {
- set global_as_options ""
- }
if ![info exists global_ld_options] {
set global_ld_options ""
}
}
set comp_output [target_assemble $srcdir/$subdir/quit.s quit.o \
- "-I$srcdir/$subdir $global_as_options"]
+ "-I$srcdir/$subdir"]
if ![string match "" $comp_output] {
verbose -log "$comp_output" 3
if [istarget cris*-*-*] {
global ASFLAGS_FOR_TARGET
set has_rv_and_cris [sim_has_rv_and_cris]
- global global_as_options
global global_ld_options
global global_sim_options
global opts
global cpu_option
global cpu_option_sep
- global global_as_options
global global_ld_options
global global_sim_options
set opts(kfail) ""
set seen_output 0
- if ![info exists global_as_options] {
- set global_as_options ""
- }
if ![info exists global_ld_options] {
set global_ld_options ""
}
}
set as_options "$as_options $cpu_option$sep$mach"
}
- regsub {(^ *| +)([^ ]+)} "$as_options $global_as_options" { -Wa,\2} c_as_options
+ regsub {(^ *| +)([^ ]+)} "$as_options" { -Wa,\2} c_as_options
if ![info exists opts(ld,$mach)] {
set opts(ld,$mach) $opts(ld)
[list "incdir=$srcdir/$subdir" "additional_flags=$c_as_options"]]
set method "compiling"
} else {
- set comp_output [target_assemble $sourcefile ${name}.o "$as_options $global_as_options"]
+ set comp_output [target_assemble $sourcefile ${name}.o "$as_options"]
set method "assembling"
}
# Runs micromips tests by adding -mmicromips to as options
proc run_micromips_test { name requested_machs } {
- global global_as_options;
- set gas_old $global_as_options;
- append global_as_options " -mmicromips "
+ global ASFLAGS_FOR_TARGET
+ set ASFLAGS_FOR_TARGET "-mmicromips"
run_sim_test $name $requested_machs
- set global_as_options $gas_old
+ unset ASFLAGS_FOR_TARGET
}
# Runs all specified tests
set all_machs "sh shdsp"
-set global_as_options ""
+global ASFLAGS_FOR_TARGET
set global_ld_options ""
foreach opt $board_variant_list {
switch "x$opt" {
- x-ml { set global_as_options "-little --defsym LITTLE=1"
+ x-ml { set ASFLAGS_FOR_TARGET "-little --defsym LITTLE=1"
set global_ld_options "-EL" }
}
}