diff options
author | Nathan Binkert <nate@binkert.org> | 2009-11-08 13:31:59 -0800 |
---|---|---|
committer | Nathan Binkert <nate@binkert.org> | 2009-11-08 13:31:59 -0800 |
commit | 708faa767763e65a2fded8aa33ac3c63cca9c84c (patch) | |
tree | b0920e30711eebf6d2529b3e51bc52e3e06c3caf /src/arch/isa_parser.py | |
parent | 48525f581c6233b8f7a8a872c5774d4e245f431c (diff) | |
download | gem5-708faa767763e65a2fded8aa33ac3c63cca9c84c.tar.xz |
compile: wrap 64bit numbers with ULL() so 32bit compiles work
In the isa_parser, we need to check case statements.
Diffstat (limited to 'src/arch/isa_parser.py')
-rwxr-xr-x | src/arch/isa_parser.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/arch/isa_parser.py b/src/arch/isa_parser.py index e3da240d2..2db7c6aa6 100755 --- a/src/arch/isa_parser.py +++ b/src/arch/isa_parser.py @@ -585,7 +585,12 @@ StaticInstPtr # 'default' def p_case_label_0(self, t): 'case_label : intlit_list' - t[0] = ': '.join(map(lambda a: 'case %#x' % a, t[1])) + def make_case(intlit): + if intlit >= 2**32: + return 'case ULL(%#x)' % intlit + else: + return 'case %#x' % intlit + t[0] = ': '.join(map(make_case, t[1])) def p_case_label_1(self, t): 'case_label : DEFAULT' |