Sasa,
I can answer about half of your concerns... I can't comment on the
LogTM side of things (but others probably will).
First of all, I don't think tourmaline is binary compatible with the
current release of LogTM -- I believe LogTM has modified the interface
substantially, and Tourmaline hasn't been kept up to date with respect
to those changes.
Second, Tourmaline is a functional simulator -- it doesn't use /any/
cache coherence protocol, because there is no timing going on. It is
around to help develop TM apps, but doesn't have a lot of features.
In short, I think you'll have better luck using Ruby instead of
Tourmaline for this.
Regards,
Dan
Sasa Vitorovic wrote:
Hello,
I have few questions about TMA:
1) I am reading some of the previous post:
https://lists.cs.wisc.edu/archive/gems-users/2006-December/msg00031.shtml
I am interesting in OS-Aborts. Next paragraph from previous link is
only for LogTM, I hope:
"RE: OS-Aborts
The trick is that Solaris (and probably Linux) doesn't like to be
aborted while in the OS -- its nontrivial to rollback OS events, like
TLB actions. Notably, disabling interrupts does not disable traps (eg
TLB and Register Window events), so aborts in the OS are rare, but can
occur.
"
As far as I know, this is in specification of LogTm-SE. Is this now
supported? Particularly, if the OS event occur, can we rool back whole
system in case of transaction abort?
2) I set up TM benchmark in ruby LogTM, but i have problems with
starting TM benchmark in TMA. Both files are made by modifying
deque.simics from microbenchmarks/transacional/deque dir.
Here is dequeTMA.simics for starting
deque bench from TMA, which does not work.
**********
@sys.path.append("../../../gen-scripts")
@import microbench, workloads, mfacet
###### Read simulation parameters
@env_dict = workloads.prepare_env_dictionary(simics = 1)
#@processors = int(workloads.get_var(env_dict, "PROCESSORS"))
#we will set it manually, this workload file can be used for other
workloads
@processors = int(4)
# 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
@ruby_proc_map = (1, 2, 2, 4, 4, 8, 8, 8, 8, 16, 16, 16, 16, 16, 16,
16, 16)
@if(processors <= 16):
ruby_procs = ruby_proc_map[processors]
#proc_no = [0, 1, 4, 5, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
19]
proc_no = [0, 0, 1, 2, 3, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]
#for processors' sets number 1 to 4, proc_no going 0 to 3
#if something goes wrong, first check the output of command psrinfo
on target console - already typed below, you should just check output
#if the number of processors greater than 16, change elif
(processors<=32)
elif (processors <= 32):
ruby_procs = 32
proc_no = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47]
else:
processors = -1
@print "running simics with %d processors" % ruby_procs
#we can see workload parameters for deque in
$GEMS/gen-scripts/workload.py
#@lock_type = workloads.get_var(env_dict, "LOCK_TYPE")
@lock_type = "TM"
#@transactions = int(workloads.get_var(env_dict, "TRANSACTIONS"))
@transactions = 20
#@dump_interval = int(workloads.get_var(env_dict, "DUMP_INTERVAL"))
@dump_interval = 1
#@arg_str = workloads.get_var(env_dict, "MBENCH_ARG_STRING")
@arg_str = "20 32"
@env_dict = workloads.prepare_env_dictionary(simics = 1)
@visualizer = int(workloads.get_var(env_dict, "XACT_VISUALIZER"))
@results_dir = workloads.get_var(env_dict, "RESULTS_DIR")
#@filename_prefix = "%s/%s" % (results_dir,
workloads.get_microbench_output_file_name_prefix(env_dict, 0))
@filename_prefix = "dequeIzlaz"
#output will be put in $GEMS/simics/home/TMTest
#@mfacet.run_sim_command('read-configuration
"../../checkpoints-u3/microbenchmark/microbenchmark-%dp.check"' %
ruby_procs)
@mfacet.run_sim_command('read-configuration
"/gems/checkpoints/sar4PsimFSgcc.check"')
@mfacet.run_sim_command('magic-break-enable')
@hostpath = "/host" + os.getcwd() +
"/../../../microbenchmarks/transactional/"
@command_lines = [
"psrinfo\n",
"PATH=$PATH:/usr/local/bin:/usr/ccs/bin\n",
"export PATH\n",
"bash\n",
"mkdir /transactional\n",
"cp -r " + hostpath + " /\n",
"umount /host\n",
"cd /transactional/deque\n",
"make\n"
]
#copied from btree.simics commented example with some modifications
## Create Processor Sets
#@for j in range(processors + 1):
#Solaris allows you to bind upto n-1 processors to various processor
sets, where n is the total number of processors in the system.
@for j in range(processors):
if(j != 0):
print "j=%d, num_p=%d" % (j, processors)
command_lines.append("psrset -c\n")
print "psrset -c\n"
command_lines.append("psrset -a %d %d\n" % (j, proc_no[j]))
print "psrset -a %d %d\n" % (j, proc_no[j])
@command_lines.append("./deque_TM %d %s\n" % (processors-1, arg_str))
#starting benchmark
@mfacet.console_commands(command_lines,"#")
c
@mfacet.run_sim_command('magic-break-enable')
@mfacet.run_sim_command('istc-disable')
@mfacet.run_sim_command('dstc-disable')
@mfacet.run_sim_command('magic-break-disable')
@mfacet.run_sim_command('cpu-switch-time 1')
@mfacet.run_sim_command('magic-break-enable')
@mfacet.run_sim_command('load-module tourmaline')
@mfacet.run_sim_command('tourmaline0.init')
@mfacet.setup_run_for_n_transactions(transactions, dump_interval)
@mfacet.run_sim_command('c')
@mfacet.run_sim_command('tourmaline0.dump-stats dequeIzlazTMA.stats')
#quit
#-----------------
**********
I am using Simics 2.2.19 and GEMS 2.1, Sarek with Solaris 9 and I made
checkpoint with 4 processors and Simics FS support. GCC also had been
installed.
My tourmaline.defaults looks like:
*****************************
// Specifies random seed. Note: if(g_RANDOM_SEED ==
0) srand(time(NULL))
g_RANDOM_SEED: 1
// Set automatically to SIMICS_number_processors() on init
g_NUMBER_OF_PROCESSORS: 0
// Must be one of the following:
// Serializer
// Generic
SPECIFIED_TRANSACTION_CONTROLLER: Serializer
g_SERIALIZATION_WARNING_ENABLE: true
g_PRINT_XACT_STATUS: false
g_SERIALIZER_N_TRANSACTIONS: 10000
*****************************
When I start this .simics file I got .stats file with zero transaction
number
********************************
begin_xact_proc0: 0
end_xact_proc0: 0
begin_xact_proc1: 0
end_xact_proc1: 0
begin_xact_proc2: 0
end_xact_proc2: 0
begin_xact_proc3: 0
end_xact_proc3: 0
******************************************
I understood that TMA is simulating without timing. But still I don't
know why transaction's counters is on 0.
Also I get warning:
"
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
end_transaction_magic_call: transaction started: 17, transaction
completed: 16, transaction_limit: 20, mem_res: 101.902344 mem_total:
131.179688 mem_ratio: 0.776815
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
Warning: in fn void magic_instruction_callback(void*, void*, integer_t)
in simics/commands.C:231: Unexpected magic call, val = 0
end_transaction_magic_call: transaction started: 17, transaction
completed: 17, transaction_limit: 20, mem_res: 101.902344 mem_total:
131.179688 mem_ratio: 0.776815
"
but I understood from this
list that this is normal behavioral for ruby, because this magic call
actually is not for ruby, it's for Tourmaline.
3) Which protocol TMA uses? In ruby LogTM there is Serializer and
Generic.
I will realy appreciate any help. I also made some tutorial step by
step for setting up simics, ruby, Opal and TMA on TM bench example.
Only part for staring TM bench in TMA is missing.
Best regards,
Sasa Vitorovic
_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
Use Google to search the GEMS Users mailing list by adding "site:https://lists.cs.wisc.edu/archive/gems-users/" to your search.
--
http://www.cs.wisc.edu/~gibson [esc]:wq!
|
|