Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fixed 64-bit integer literal support
  • Loading branch information
Kyle Miller committed Apr 25, 2012
1 parent e8d4f58 commit 13d6c48
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Assembly.hs
Expand Up @@ -325,7 +325,8 @@ instance Show (Asm e x) where
(show sname) (show reg) (showPos pos)
show (MovIRMtoR pos a b) = showBinOp "movq" pos a b
show (MovIRtoM pos a b) = showBinOp "movq" pos a b
show (Mov64toR pos a b) = showBinOp "movq" pos a b
show (Mov64toR pos a b) = printf "%s $%s, %s # %s"
"movq" (show a) (show b) (showPos pos)

show (CMovRMtoR pos flag a b) = showBinOp opcode pos a b
where opcode = "cmov" ++ show flag ++ "q"
Expand Down
6 changes: 6 additions & 0 deletions tests/codegen/largeint.dcf
@@ -0,0 +1,6 @@
//>22222222222222
class Program {
void main() {
callout("printf", "%lld\n", 22222222222222);
}
}

0 comments on commit 13d6c48

Please sign in to comment.