Minero Aoki
41d6488cfa
* net/loveruby/cflat/compiler/Options.java: --version did not print "\n".
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4305 1b9489fe-b721-0410-924e-b54b9192deb8
2009-07-05 20:22:00 +00:00
Minero Aoki
f54cfaab75
fix preproc tags
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4303 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-27 16:09:22 +00:00
Minero Aoki
4ec1db3eea
fix preproc tags
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4302 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-27 08:26:27 +00:00
Minero Aoki
9ada80d267
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: rename method: doesIndirectAccess -> shouldUsePLT.
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4299 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-21 10:15:42 +00:00
Minero Aoki
eedb1294e3
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: assign address for gvar.
...
* net/loveruby/cflat/entity/Entity.java: accept imm address.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4298 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-21 08:15:21 +00:00
Minero Aoki
274b12a6cd
* net/loveruby/cflat/compiler/Options.java: rename option: --readonly-plt -> --readonly-got.
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4297 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-21 08:14:50 +00:00
Minero Aoki
b26702992c
* net/loveruby/cflat/sysdep/GNULinker.java: parameterize linker path.
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4296 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-20 18:48:32 +00:00
Minero Aoki
578e495480
r5116@macbookpro: aamine | 2009-06-15 01:05:26 +0900
...
* net/loveruby/cflat/compiler/Options.java (parseCommaSeparatedOptions): AbstractList does not support #remove.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4293 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-16 07:43:21 +00:00
Minero Aoki
ee8432d4fa
r5104@macbookpro: aamine | 2009-06-13 22:43:16 +0900
...
* rename class: AssemblyFile -> AssemblyCode.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4292 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-13 13:46:36 +00:00
Minero Aoki
0837912b64
r5103@macbookpro: aamine | 2009-06-13 22:37:55 +0900
...
* net/loveruby/cflat/entity/ToplevelScope.java: move #definedGlobalVariables and #definedCommonSymbols to IR.
* net/loveruby/cflat/ir/IR.java: ditto.
* net/loveruby/cflat/ir/IR.java: new method #isGlobalVariableDefined.
* net/loveruby/cflat/ir/IR.java: new method #isCommonSymbolDefined.
* net/loveruby/cflat/ir/IR.java: new method #isStringLiteralDefined.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: use these methods.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4291 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-13 13:46:35 +00:00
Minero Aoki
fd591cf2b7
r5100@macbookpro: aamine | 2009-06-13 17:42:06 +0900
...
* net/loveruby/cflat/utils/CommandUtils.java: better error message.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4289 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-13 08:42:32 +00:00
Minero Aoki
ec67762360
add preproc tag
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4287 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-13 06:31:18 +00:00
Minero Aoki
062c8b831a
preproc tags added
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4285 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-07 21:36:56 +00:00
Minero Aoki
092ff61e93
add preproc tags
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4284 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-07 20:40:38 +00:00
Minero Aoki
592bff7634
r5053@macbookpro: aamine | 2009-06-08 05:39:37 +0900
...
spacing change only
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4283 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-07 20:40:07 +00:00
Minero Aoki
6ba72a960e
preproc tags added
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4282 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-07 05:48:21 +00:00
Minero Aoki
7c9845ecaa
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (StackFrameInfo): shorten code using CodeGenerator constant directly.
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4281 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-07 04:42:21 +00:00
Minero Aoki
7d4223ba6a
just spacing changes
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4280 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-07 04:36:00 +00:00
Minero Aoki
6833982356
r5034@macbookpro: aamine | 2009-06-07 04:17:22 +0900
...
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: extract class: StackFrameInfo.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: extract method: generateFunctionBody.
net/loveruby/cflat/entity/DefinedFunction.java: new method #lvarScope.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4279 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-06 19:17:42 +00:00
Minero Aoki
8f9df4fb03
r5033@macbookpro: aamine | 2009-06-07 03:17:50 +0900
...
* sysdep/x86/CodeGenerator.java (compileFunctionBody): fix offset bug.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4278 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-06 19:17:42 +00:00
Minero Aoki
4ac683c9d7
r5032@macbookpro: aamine | 2009-06-07 03:03:18 +0900
...
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring compileFunctionBody.
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: objectify VirtualStack.
* net/loveruby/cflat/asm/IndirectMemoryReference.java: new method .relocatable to generate relocatable IndirectMemoryReference.
* net/loveruby/cflat/asm/MemoryReference.java: new method #fixOffset.
* net/loveruby/cflat/asm/DirectMemoryReference.java: new method #fixOffset.
* net/loveruby/cflat/asm/Assembly.java: remove fixStackOffset.
* net/loveruby/cflat/asm/Operand.java: ditto.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4277 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-06 19:17:41 +00:00
Minero Aoki
4cf7bd2ae8
* sysdep/x86/CodeGenerator.java: refactoring: rename method: allocateParameters -> locateParameters.
...
* sysdep/x86/CodeGenerator.java: refactoring: rename method: allocateLocalVariablesTemp -> locateLocalVariables.
* sysdep/x86/CodeGenerator.java: refactoring: rename method: allocateLocalVariables -> fixLocalVariableOffsets.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4275 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-06 12:28:29 +00:00
Minero Aoki
6775112ebf
r5013@macbookpro: aamine | 2009-06-01 06:40:51 +0900
...
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: rename method: save -> store.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4274 1b9489fe-b721-0410-924e-b54b9192deb8
2009-06-06 07:29:22 +00:00
Minero Aoki
23d0fb9091
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (load, save): reduce # of arguments.
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4272 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-31 20:43:15 +00:00
Minero Aoki
1a7d027bee
r5009@macbookpro: aamine | 2009-06-01 03:56:40 +0900
...
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (Bin): optimize more patterns.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4271 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-31 18:57:00 +00:00
Minero Aoki
694aa209f3
r4998@macbookpro: aamine | 2009-05-31 22:33:21 +0900
...
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: rename method.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (Int): simplify code.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4270 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-31 13:34:00 +00:00
Minero Aoki
3b566ad27c
r4994@macbookpro: aamine | 2009-05-27 01:59:19 +0900
...
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: remove unused methods.
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: reduce Type argument.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: follow changes.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4267 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 17:06:04 +00:00
Minero Aoki
9805e5c958
change preproc tags
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4266 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 07:53:13 +00:00
Minero Aoki
f5c2ed0b30
r4987@macbookpro: aamine | 2009-05-26 16:52:33 +0900
...
* net/loveruby/cflat/asm/NamedSymbol.java (dump): dump name as string.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4265 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 07:52:45 +00:00
Minero Aoki
8049035053
r4986@macbookpro: aamine | 2009-05-26 16:07:49 +0900
...
* net/loveruby/cflat/compiler/Compiler.java: --dump-asm now dumps AssemblyFile.
* net/loveruby/cflat/compiler/Compiler.java: new option --print-asm, prints assembly source text.
* net/loveruby/cflat/compiler/CompilerMode.java: new enum PrintAsm.
* net/loveruby/cflat/compiler/Options.java: new option --print-asm.
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: new method #dump.
* net/loveruby/cflat/sysdep/x86/Register.java: new method #dump.
* net/loveruby/cflat/asm: new method #dump.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4264 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 07:52:44 +00:00
Minero Aoki
144393f6d4
r4985@macbookpro: aamine | 2009-05-26 15:16:21 +0900
...
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: refactoring: apply strict visibility.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4263 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 07:52:42 +00:00
Minero Aoki
1729dbaac0
r4984@macbookpro: aamine | 2009-05-26 15:11:36 +0900
...
* net/loveruby/cflat/compiler/Compiler.java: change CodeGenerator output: String -> AssemblyFile.
* net/loveruby/cflat/sysdep/AssemblyFile.java: new interface.
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: implement it.
* net/loveruby/cflat/sysdep/CodeGenerator.java: #generate returns AssemblyFile.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: ditto.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4262 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 07:52:42 +00:00
Minero Aoki
b38ec78fdc
r4982@macbookpro: aamine | 2009-05-26 13:40:29 +0900
...
* net/loveruby/cflat/sysdep/x86: rename class: RegKind -> RegisterClass.
* net/loveruby/cflat/sysdep/x86: follow it.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4261 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:41:56 +00:00
Minero Aoki
a1832aca6b
r4972@macbookpro: aamine | 2009-05-26 13:24:13 +0900
...
* net/loveruby/cflat/asm: refactoring: rename class: AsmStatistics -> Statistics.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: follow it.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4260 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:48 +00:00
Minero Aoki
aabbca6e13
r4971@macbookpro: aamine | 2009-05-26 13:19:10 +0900
...
* net/loveruby/cflat/asm: refactoring: rename class: AsmOperand -> Operand.
* net/loveruby/cflat/asm: follow it.
* net/loveruby/cflat/sysdep/x86: follow it.
* net/loveruby/cflat/ir: follow it.
* net/loveruby/cflat/entity: follow it.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4259 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:46 +00:00
Minero Aoki
039483da62
r4970@macbookpro: aamine | 2009-05-26 13:11:26 +0900
...
* net/loveruby/cflat/asm/AsmComment.java -> Comment.java
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4258 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:45 +00:00
Minero Aoki
d50cb63ee5
r4969@macbookpro: aamine | 2009-05-26 12:58:04 +0900
...
* net/loveruby/cflat/compiler/Compiler.java (writeFile): treat "-" as stdout.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4257 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:44 +00:00
Minero Aoki
e593745d2e
r4968@macbookpro: aamine | 2009-05-26 12:48:57 +0900
...
* net/loveruby/cflat/compiler/Compiler.java (dumpAsm): do not print extra '\n'.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4256 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:43 +00:00
Minero Aoki
7ce8034b0f
r4967@macbookpro: aamine | 2009-05-26 12:21:40 +0900
...
* net/loveruby/cflat/compiler/Options.java: check unknown file types.
* net/loveruby/cflat/compiler/SourceFile.java: new method #isKnownFileType.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4255 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:42 +00:00
Minero Aoki
e6b6f20d24
r4966@macbookpro: aamine | 2009-05-26 11:59:25 +0900
...
* net/loveruby/cflat/compiler/Options.java: allow --verbose-asm too.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4254 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 04:24:41 +00:00
Minero Aoki
c30f91a58a
r4964@macbookpro: aamine | 2009-05-26 11:50:29 +0900
...
* net/loveruby/cflat/compiler/Options.java: --verbose-asm -> -fverbose-asm
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4253 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-26 02:52:20 +00:00
Minero Aoki
53e8ae748d
fix preproc tag only
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4252 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 14:37:24 +00:00
Minero Aoki
9fc50d2179
fix preproc tags only
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4251 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 14:08:43 +00:00
Minero Aoki
64e91a4737
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: reorder methods.
...
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring: inlining #testCond.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4248 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 13:44:10 +00:00
Minero Aoki
b9ad38ef16
r4942@macbookpro: aamine | 2009-05-24 21:56:17 +0900
...
* net/loveruby/cflat/compiler/IRGenerator.java: do not use Expr#isConstantAddress, it confuses semantics.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: ditto.
* net/loveruby/cflat/ir/Expr.java: introduce new methods #isVar and #isAddr, instead of #isConstantAddress.
* net/loveruby/cflat/ir/Addr.java: override #isAddr.
* net/loveruby/cflat/ir/Var.java: override #isVar.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4247 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 12:56:38 +00:00
Minero Aoki
118d27b4ef
r4941@macbookpro: aamine | 2009-05-24 21:54:18 +0900
...
* net/loveruby/cflat/ast: remove useless methods: ExprNode#isConstantAddress.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4246 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 12:56:37 +00:00
Minero Aoki
de2d14c1fb
modify preproc range
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4245 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 12:29:15 +00:00
Minero Aoki
2871c6d19d
add preproc tags.
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4244 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 12:18:09 +00:00
Minero Aoki
4d889a2588
r4907@macbookpro: aamine | 2009-05-24 20:23:14 +0900
...
* net/loveruby/cflat/compiler/IRGenerator.java (Dereference): do not generate Mem for unloadable object (implicit address generation handling).
* net/loveruby/cflat/ast: dump #type for LHS nodes.
* net/loveruby/cflat/ast/AddressNode.java: do not inherit UnaryOpNode.
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4241 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 11:23:29 +00:00
Minero Aoki
0fd4bbfad3
fix preproc tag
...
git-svn-id: file:///Users/aamine/c/gitwork/public/cbc/trunk@4240 1b9489fe-b721-0410-924e-b54b9192deb8
2009-05-24 10:23:30 +00:00