diff -r 9b48b795bfc5 -r b71d3f7eb6e6 SConstruct --- a/SConstruct Fri Jul 15 21:26:18 2011 -0400 +++ b/SConstruct Fri Jul 22 00:50:49 2011 -0500 @@ -807,7 +807,6 @@ BoolVariable('USE_FENV', 'Use IEEE mode control', have_fenv), BoolVariable('USE_CHECKER', 'Use checker for detailed CPU models', False), BoolVariable('CP_ANNOTATE', 'Enable critical path annotation capability', False), - BoolVariable('RUBY', 'Build with Ruby', False), ) # These variables get exported to #defines in config/*.hh (see src/SConscript). @@ -982,6 +981,11 @@ if env['USE_SSE2']: env.Append(CCFLAGS=['-msse2']) + if env['PROTOCOL'] != 'None': + env['RUBY'] = True + else: + env['RUBY'] = False + # The src/SConscript file sets up the build rules in 'env' according # to the configured variables. It returns a list of environments, # one for each variant build (debug, opt, etc.) diff -r 9b48b795bfc5 -r b71d3f7eb6e6 build_opts/ALPHA_SE --- a/build_opts/ALPHA_SE Fri Jul 15 21:26:18 2011 -0400 +++ b/build_opts/ALPHA_SE Fri Jul 22 00:50:49 2011 -0500 @@ -1,4 +1,3 @@ FULL_SYSTEM = 0 SS_COMPATIBLE_FP = 1 CPU_MODELS = 'AtomicSimpleCPU,TimingSimpleCPU,O3CPU,InOrderCPU' -PROTOCOL = 'MI_example' diff -r 9b48b795bfc5 -r b71d3f7eb6e6 build_opts/ALPHA_SE_MESI_CMP_directory --- a/build_opts/ALPHA_SE_MESI_CMP_directory Fri Jul 15 21:26:18 2011 -0400 +++ b/build_opts/ALPHA_SE_MESI_CMP_directory Fri Jul 22 00:50:49 2011 -0500 @@ -2,4 +2,3 @@ SS_COMPATIBLE_FP = 1 CPU_MODELS = 'AtomicSimpleCPU,TimingSimpleCPU,O3CPU,InOrderCPU' PROTOCOL = 'MESI_CMP_directory' -RUBY = True diff -r 9b48b795bfc5 -r b71d3f7eb6e6 build_opts/ALPHA_SE_MOESI_CMP_directory --- a/build_opts/ALPHA_SE_MOESI_CMP_directory Fri Jul 15 21:26:18 2011 -0400 +++ b/build_opts/ALPHA_SE_MOESI_CMP_directory Fri Jul 22 00:50:49 2011 -0500 @@ -2,4 +2,3 @@ SS_COMPATIBLE_FP = 1 CPU_MODELS = 'AtomicSimpleCPU,TimingSimpleCPU,O3CPU,InOrderCPU' PROTOCOL = 'MOESI_CMP_directory' -RUBY = True diff -r 9b48b795bfc5 -r b71d3f7eb6e6 build_opts/ALPHA_SE_MOESI_CMP_token --- a/build_opts/ALPHA_SE_MOESI_CMP_token Fri Jul 15 21:26:18 2011 -0400 +++ b/build_opts/ALPHA_SE_MOESI_CMP_token Fri Jul 22 00:50:49 2011 -0500 @@ -2,4 +2,3 @@ SS_COMPATIBLE_FP = 1 CPU_MODELS = 'AtomicSimpleCPU,TimingSimpleCPU,O3CPU,InOrderCPU' PROTOCOL = 'MOESI_CMP_token' -RUBY = True diff -r 9b48b795bfc5 -r b71d3f7eb6e6 build_opts/ALPHA_SE_MOESI_hammer --- a/build_opts/ALPHA_SE_MOESI_hammer Fri Jul 15 21:26:18 2011 -0400 +++ b/build_opts/ALPHA_SE_MOESI_hammer Fri Jul 22 00:50:49 2011 -0500 @@ -2,4 +2,3 @@ SS_COMPATIBLE_FP = 1 CPU_MODELS = 'AtomicSimpleCPU,TimingSimpleCPU,O3CPU,InOrderCPU' PROTOCOL = 'MOESI_hammer' -RUBY = True diff -r 9b48b795bfc5 -r b71d3f7eb6e6 build_opts/ALPHA_SE_Network_test --- a/build_opts/ALPHA_SE_Network_test Fri Jul 15 21:26:18 2011 -0400 +++ b/build_opts/ALPHA_SE_Network_test Fri Jul 22 00:50:49 2011 -0500 @@ -2,4 +2,3 @@ SS_COMPATIBLE_FP = 1 CPU_MODELS = 'AtomicSimpleCPU,TimingSimpleCPU,O3CPU,InOrderCPU' PROTOCOL = 'Network_test' -RUBY = True diff -r 9b48b795bfc5 -r b71d3f7eb6e6 configs/example/se.py --- a/configs/example/se.py Fri Jul 15 21:26:18 2011 -0400 +++ b/configs/example/se.py Fri Jul 22 00:50:49 2011 -0500 @@ -71,13 +71,12 @@ parser.add_option("--output", default="", help="Redirect stdout to a file.") parser.add_option("--errout", default="", help="Redirect stderr to a file.") -if 'PROTOCOL' in buildEnv: - parser.add_option("--ruby", action="store_true") - execfile(os.path.join(config_root, "common", "Options.py")) -if '--ruby' in sys.argv: - Ruby.define_options(parser) +if buildEnv['PROTOCOL'] != 'None': + parser.add_option("--ruby", action="store_true") + if '--ruby' in sys.argv: + Ruby.define_options(parser) (options, args) = parser.parse_args() diff -r 9b48b795bfc5 -r b71d3f7eb6e6 src/mem/protocol/SConsopts --- a/src/mem/protocol/SConsopts Fri Jul 15 21:26:18 2011 -0400 +++ b/src/mem/protocol/SConsopts Fri Jul 22 00:50:49 2011 -0500 @@ -34,24 +34,15 @@ all_protocols = [ 'MESI_CMP_directory', - 'MESI_SCMP_bankdirectory', - 'MESI_SCMP_bankdirectory_m', 'MI_example', 'MOESI_CMP_directory', - 'MOESI_CMP_directory_m', 'MOESI_CMP_token', - 'MOESI_SMP_directory', - 'MOESI_SMP_token', - 'MOSI_SMP_bcast', - 'MOSI_SMP_bcast_1level', - 'MOSI_SMP_bcast_m', - 'MOSI_SMP_directory_1level', - 'MSI_MOSI_CMP_directory', 'MOESI_hammer', 'Network_test', + 'None' ] -opt = EnumVariable('PROTOCOL', 'Coherence protocol for Ruby', 'MI_example', +opt = EnumVariable('PROTOCOL', 'Coherence protocol for Ruby', 'None', all_protocols) sticky_vars.AddVariables(opt)