forked from aamine/cbc
-
Notifications
You must be signed in to change notification settings - Fork 52
/
ChangeLog
5857 lines (3361 loc) · 165 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
Sun Jul 19 14:21:42 2009 Minero Aoki <[email protected]>
* test/test_cbc.sh: do not override CBC environment.
Mon Jul 6 05:21:24 2009 Minero Aoki <[email protected]>
* install.sh: tested.
Mon Jul 6 05:20:56 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java: --version did not
print "\n".
Sun Jun 21 19:15:19 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring:
rename method: doesIndirectAccess -> shouldUsePLT.
Sun Jun 21 17:14:56 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: assign address
for gvar.
* net/loveruby/cflat/entity/Entity.java: accept imm address.
Sun Jun 21 17:14:19 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java: rename option:
--readonly-plt -> --readonly-got.
Sun Jun 21 03:48:12 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/GNULinker.java: parameterize linker
path.
Sun Jun 21 03:47:05 2009 Minero Aoki <[email protected]>
* import/stdlib.hb: add system() prototype.
Thu Jun 18 00:45:50 2009 Minero Aoki <[email protected]>
* lib/Makefile: use 's' option to create index.
Sun Jun 14 23:44:47 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java
(parseCommaSeparatedOptions): AbstractList does not support
#remove.
Sat Jun 13 22:42:24 2009 Minero Aoki <[email protected]>
* rename class: AssemblyFile -> AssemblyCode.
Sat Jun 13 22:37:02 2009 Minero Aoki <[email protected]>
* 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.
Sat Jun 13 17:41:13 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/utils/CommandUtils.java: better error
message.
Sun Jun 7 13:42:15 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java
(StackFrameInfo): shorten code using CodeGenerator constant
directly.
Sun Jun 7 04:16:39 2009 Minero Aoki <[email protected]>
* 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.
Sun Jun 7 03:17:06 2009 Minero Aoki <[email protected]>
* sysdep/x86/CodeGenerator.java (compileFunctionBody): fix offset
bug.
Sun Jun 7 03:02:35 2009 Minero Aoki <[email protected]>
* 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.
Sat Jun 6 21:36:09 2009 Minero Aoki <[email protected]>
* lib/alloca.s: shorten assembly.
Sat Jun 6 21:28:20 2009 Minero Aoki <[email protected]>
* 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.
Mon Jun 1 06:39:57 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring:
rename method: save -> store.
Mon Jun 1 05:43:13 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (load, save):
reduce # of arguments.
Mon Jun 1 03:55:41 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (Bin): optimize
more patterns.
Sun May 31 22:32:29 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring:
rename method.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (Int): simplify
code.
Wed May 27 01:59:03 2009 Minero Aoki <[email protected]>
* 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.
Tue May 26 16:52:18 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/asm/NamedSymbol.java (dump): dump name as
string.
Tue May 26 16:07:33 2009 Minero Aoki <[email protected]>
* 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.
Tue May 26 15:16:04 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: refactoring:
apply strict visibility.
Tue May 26 15:11:19 2009 Minero Aoki <[email protected]>
* 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.
Tue May 26 13:40:13 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86: rename class: RegKind ->
RegisterClass.
* net/loveruby/cflat/sysdep/x86: follow it.
Tue May 26 13:23:56 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/asm: refactoring: rename class: AsmStatistics
-> Statistics.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: follow it.
Tue May 26 13:18:52 2009 Minero Aoki <[email protected]>
* 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.
Tue May 26 13:11:08 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/asm/AsmComment.java -> Comment.java
Tue May 26 12:57:48 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java (writeFile): treat "-"
as stdout.
Tue May 26 12:48:40 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java (dumpAsm): do not
print extra '\n'.
Tue May 26 12:21:18 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java: check unknown file
types.
* net/loveruby/cflat/compiler/SourceFile.java: new method
#isKnownFileType.
Tue May 26 11:59:08 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java: allow --verbose-asm
too.
Tue May 26 11:50:11 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java: --verbose-asm ->
-fverbose-asm
Sun May 24 22:44:07 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring:
reorder methods.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: refactoring:
inlining #testCond.
Sun May 24 21:57:04 2009 Minero Aoki <[email protected]>
* 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.
Sun May 24 21:54:57 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/ast: remove useless methods:
ExprNode#isConstantAddress.
Sun May 24 20:24:01 2009 Minero Aoki <[email protected]>
* 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.
Sun May 24 19:23:28 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/TypeResolver.java: now 3 pathes
(define, resolve entities, resolve expr) are not required; just
use old 2 pathes (define, resolve). Old TypeResolver fixed a type
of AddressNode, it requires 3 path. But current implementation
fixes a type of AddressNode in DereferenceChecker, we do not need
3 path.
* net/loveruby/cflat/ast/AST.java: #entities -> #definitions.
* net/loveruby/cflat/ast/AST.java: new method #entities, it
returns #definitions + #declarations.
* net/loveruby/cflat/compiler/TypeResolver.java: follow it.
* net/loveruby/cflat/compiler/LocalResolver.java: follow it.
Sun May 24 11:58:15 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java (If): refactoring:
increase readability.
Sun May 24 02:08:47 2009 Minero Aoki <[email protected]>
* utilize final field.
Sun May 24 01:18:36 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: reorder methods.
Sun May 24 00:42:28 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/ir: rename class: BranchIf -> CJump.
* net/loveruby/cflat/ir/IRVisitor.java: follow it.
* net/loveruby/cflat/compiler/IRGenerator.java: ditto.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: ditto.
Sun May 24 00:01:07 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: refactoring:
reorder stmts.
Sat May 23 23:31:17 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: refactoring: use
reverse(node.args) instead of ListIterator.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: ditto.
* net/loveruby/cflat/utils/ListUtils.java: new utility class.
* net/loveruby/cflat/ast/FuncallNode.java: remove #finalArgs.
* net/loveruby/cflat/ir/Call.java: ditto.
* net/loveruby/cflat/ast/FuncallNode.java: refactoring: rename
method: arguments -> args.
* net/loveruby/cflat/compiler/Visitor.java: follow it.
* net/loveruby/cflat/compiler/TypeChecker.java: ditto.
Sat May 23 22:31:06 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/parser/Parser.jj: now NULL is not a reserved
word.
* import/stddef.hb: define const NULL.
Sat May 23 22:22:11 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: refactoring:
rename method: deref -> mem
* net/loveruby/cflat/type/ArrayType.java: remove useless
definition of #isScalar.
Sat May 23 21:33:55 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: refactoring:
extract method: #bin.
* net/loveruby/cflat/compiler/IRGenerator.java: refactoring:
extract method: #isPointerDiff.
* net/loveruby/cflat/compiler/IRGenerator.java: refactoring:
extract method: #isPointerArithmetic.
* net/loveruby/cflat/type/TypeTable.java: new method #longSize.
* net/loveruby/cflat/ast/ExprNode.java: remove unused method
#baseSize.
Mon May 18 04:52:25 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/TypeChecker.java: allow ptr-ptr.
* net/loveruby/cflat/compiler/IRGenerator.java: implement ptr-ptr.
* net/loveruby/cflat/type/VoidType.java: VoidType#size is 1.
* net/loveruby/cflat/ast/ExprNode.java: new helper method
#baseType.
Mon May 18 03:50:55 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java (optimize):
wrongly did not optimize asm code.
Mon May 18 03:29:59 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/TypeResolver.java: move x[] -> x*
code to DereferenceChecker.
* net/loveruby/cflat/compiler/DereferenceChecker.java: ditto.
* net/loveruby/cflat/compiler/Compiler.java: pass TypeTable to
DereferenceChecker.
Mon May 18 03:01:22 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/parser/Parser.jj: change function pointer
syntax: int(*)(int,int) -> int(int,int)*. Function type is
int(int,int).
* net/loveruby/cflat/parser/Parser.jj: function returns function
type, not pointer to function.
* net/loveruby/cflat/compiler/TypeResolver.java: resolve all
function headers first, then resolve bodies.
* net/loveruby/cflat/compiler/TypeResolver.java: generate a
pointer for array-type expression.
* net/loveruby/cflat/compiler/TypeResolver.java: isDereferable ->
isPointer.
* net/loveruby/cflat/compiler/TypeChecker.java: ditto.
* net/loveruby/cflat/compiler/DereferenceChecker.java: ditto.
* net/loveruby/cflat/compiler/IRGenerator.java: ditto.
* net/loveruby/cflat/compiler/IRGenerator.java:
shouldEvaluatedToAddress -> isLoadable (check arrays and
functions, not only arrays).
* net/loveruby/cflat/type/Type.java: remove #isDereferable.
* net/loveruby/cflat/type/UserType.java: ditto.
* net/loveruby/cflat/type/ArrayType.java: is not a scalar.
* net/loveruby/cflat/type/ArrayType.java: is not dereferable
itself.
* net/loveruby/cflat/type/PointerType.java: is incompatible with
arrays.
* net/loveruby/cflat/type/IntegerType.java: ditto.
* net/loveruby/cflat/type/FunctionType.java: is callable.
* net/loveruby/cflat/type/ParamTypeRefs.java: x[] -> x* for param
types.
* net/loveruby/cflat/type/TypeTable.java: new method
#getParamType.
* net/loveruby/cflat/ast/ExprNode.java: new method #isLvalue.
* net/loveruby/cflat/ast/ExprNode.java: new method #isAssignable.
* net/loveruby/cflat/ast/ExprNode.java: new method #isLoadable.
* net/loveruby/cflat/ast/CastNode.java: delegate them.
* net/loveruby/cflat/ast/LHSNode.java: new super class of LHS
nodes.
* net/loveruby/cflat/ast/VariableNode.java: ditto.
* net/loveruby/cflat/ast/DereferenceNode.java: ditto.
* net/loveruby/cflat/ast/ArefNode.java: ditto.
* net/loveruby/cflat/ast/MemberNode.java: ditto.
* net/loveruby/cflat/ast/PtrMemberNode.java: ditto.
* net/loveruby/cflat/entity/Entity.java: remove #cannotLoad.
* net/loveruby/cflat/entity/Function.java: ditto.
* net/loveruby/cflat/entity/Variable.java: ditto.
* net/loveruby/cflat/entity/Constant.java: ditto.
* net/loveruby/cflat/ir/Addr.java: is not LHS node now.
Sun May 17 16:37:26 2009 Minero Aoki <[email protected]>
* import/dlfcn.hb: new declaration file dlfcn.hb.
Sun May 17 16:36:49 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/entity/ToplevelScope.java: do not warn unused
constant.
Sun May 17 16:33:24 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/parser/Parser.jj: support constant
definition.
* net/loveruby/cflat/ast/Declarations.java: hold constants.
* net/loveruby/cflat/ast/AST.java: ditto.
* net/loveruby/cflat/compiler/LocalResolver.java: resolve
constants.
* net/loveruby/cflat/compiler/TypeResolver.java: resolve
constants.
* net/loveruby/cflat/compiler/IRGenerator.java: transform
constants reference into literal value.
* net/loveruby/cflat/compiler/DereferenceChecker.java: check if
toplevel variable initializer consists of a literal.
* net/loveruby/cflat/compiler/DereferenceChecker.java: check if
constant value consists of a literal.
* net/loveruby/cflat/ast/ExprNode.java: new method #isConstant.
* net/loveruby/cflat/ast/LiteralNode.java: override.
* net/loveruby/cflat/entity/Entity.java: support Constant.
* net/loveruby/cflat/entity/Constant.java: new entity.
* net/loveruby/cflat/entity/EntityVisitor.java: add Constant.
Sun May 17 16:18:08 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Options.java: cbc --dump-* did not
work.
Sat May 16 18:10:31 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: fix typo.
Sat May 16 18:03:22 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: parameterize
naturalType.
* net/loveruby/cflat/sysdep/X86Linux.java: provide parameter.
Sat May 16 17:48:49 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: use Type
instead of size.
Sat May 16 17:20:36 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/asm/Register.java: use enum for register
name.
* net/loveruby/cflat/sysdep/x86/RegKind.java: new enum.
* net/loveruby/cflat/sysdep/x86/Register.java: move system
dependent code to sysdep/x86/Register.
* net/loveruby/cflat/asm/IndirectMemoryReference.java: reduce
dependency to Register method.
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: use RegKind.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: reg(*) ->
ax(), bx(), cx(), ...
Wed May 13 03:22:46 2009 Minero Aoki <[email protected]>
* compiler/Compiler.java: grand refactoring.
* compiler/Options.java: refactoring: avoid ping-pong call with
SourceFile.
* compiler/SourceFile.java: ditto.
* ast/AST.java: does not contain a TypeTable.
* compiler/IRGenerator.java
* compiler/TypeResolver.java
* compiler/TypeChecker.java
* sysdep/Linker.java: change arg order.
* sysdep/GNULinker.java: ditto.
Wed May 13 01:22:12 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/utils/CommandUtils.java: accept a list of
string instead of CommandArg.
* net/loveruby/cflat/sysdep/Linker.java: ditto.
* net/loveruby/cflat/sysdep/LinkerOptions.java: ditto.
* net/loveruby/cflat/sysdep/GNULinker.java: ditto.
* net/loveruby/cflat/sysdep/AssemblerOptions.java: ditto.
* net/loveruby/cflat/sysdep/GNUAssembler.java: ditto.
* net/loveruby/cflat/utils/CommandArgStr.java ->
compiler/LdOption.java
* net/loveruby/cflat/utils/CommandArg.java -> compiler/LdArg.java
* net/loveruby/cflat/compiler/SourceFile.java: CommandArg ->
LdArg.
* net/loveruby/cflat/compiler/Compiler.java: ditto.
* net/loveruby/cflat/compiler/Options.java: ditto.
Mon May 11 03:17:32 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java: objectify assembler.
* net/loveruby/cflat/compiler/Compiler.java: objectify linker.
* net/loveruby/cflat/compiler/Options.java: provide #assembler,
#asOptions, #linker, #ldOptions.
* net/loveruby/cflat/sysdep/x86/X86Linux.java ->
sysdep/X86Linux.java
* net/loveruby/cflat/sysdep/Platform.java: provide #assembler,
#linker.
* net/loveruby/cflat/sysdep/X86Linux.java: ditto.
* net/loveruby/cflat/sysdep/Assembler.java: new interface.
* net/loveruby/cflat/sysdep/AssemblerOptions.java: new class.
* net/loveruby/cflat/sysdep/GNUAssembler.java: new Assembler
implementation.
* net/loveruby/cflat/sysdep/Linker.java: new interface.
* net/loveruby/cflat/sysdep/LinkerOptions.java: new clas.
* net/loveruby/cflat/sysdep/GNULinker.java: new Linker
implementation.
* net/loveruby/cflat/utils/CommandUtils.java: new class.
* net/loveruby/cflat/compiler/LdArg.java -> utils/CommandArg.java
* net/loveruby/cflat/compiler/LdOption.java ->
utils/CommandArgStr.java
* net/loveruby/cflat/compiler/SourceFile.java: implements
CommandArg.
Mon May 11 01:49:29 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/parser/Parser.jj: use JDK_VERSION="1.5" to
suppress warnings.
Mon May 11 01:47:51 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/codegenerator/CodeGenerator.java ->
net/loveruby/cflat/sysdep
* net/loveruby/cflat/codegenerator/CodeGeneratorOptions.java ->
net/loveruby/cflat/sysdep
* net/loveruby/cflat/sysdep/Platform.java: ditto.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: ditto.
* net/loveruby/cflat/sysdep/x86/X86Linux.java: ditto.
* net/loveruby/cflat/compiler/Compiler.java: ditto.
* net/loveruby/cflat/compiler/Options.java: ditto.
Mon May 11 01:40:28 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: use
PeepholeOptimizer directly.
* net/loveruby/cflat/asm/PeepholeOptimizer.java ->
net/loveruby/cflat/sysdep/x86
* net/loveruby/cflat/asm/AsmOptimizer.java: removed.
* net/loveruby/cflat/codegenerator/CodeGeneratorOptions.java:
should not provide PeepholeOptimizer, just provide
optimizationLevel.
Mon May 11 01:31:29 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java: move dumper code to
AST to minimize Compiler code.
* net/loveruby/cflat/ast/AST.java: add dumper code.
Mon May 11 01:05:58 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: generate address
expression for LHS expr.
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: remove
#compileLHS. Just compile LHS expr.
* net/loveruby/cflat/ir/Addr.java: is a constant address now.
* net/loveruby/cflat/ir/Var.java: is not a constant address now.
* net/loveruby/cflat/ir/Expr.java: new base method #addressNode.
* net/loveruby/cflat/ir/Mem.java: override #addressNode.
* net/loveruby/cflat/ir/Var.java: ditto.
* net/loveruby/cflat/ir/Addr.java: ditto.
* net/loveruby/cflat/ir/Expr.java: new base method
#getEntityForce.
* net/loveruby/cflat/ir/Var.java: override #getEntityForce.
* net/loveruby/cflat/ir/Addr.java: ditto.
* net/loveruby/cflat/ir/Call.java: get function entity by
Expr#getEntityForce.
Sun May 10 23:49:24 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/parser/Parser.jj: define SOURCE_ENCODING here
(again).
* net/loveruby/cflat/compiler/Constants.java: removed.
* net/loveruby/cflat/compiler/CodeGenerator.java ->
net/loveruby/cflat/codegenerator
* net/loveruby/cflat/compiler/CodeGeneratorOptions.java ->
net/loveruby/cflat/codegenerator
* net/loveruby/cflat/compiler/Platform.java ->
net/loveruby/cflat/sysdep
* net/loveruby/cflat/compiler/ErrorHandler.java ->
net/loveruby/cflat/utils
* net/loveruby/cflat/compiler/LibraryLoader.java ->
net/loveruby/cflat/parser
Sun May 10 23:04:44 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: move virtual
stack to AssemblyFile.
* net/loveruby/cflat/sysdep/x86/AssemblyFile.java: ditto.
Sun May 10 22:46:47 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86/CodeGenerator.java: protected ->
private.
Sun May 10 22:42:07 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/sysdep/x86: new package.
* net/loveruby/cflat/asm/ELFConstants.java ->
net/loveruby/cflat/sysdep/x86
* net/loveruby/cflat/asm/AssemblyFile.java ->
net/loveruby/cflat/sysdep/x86
net/loveruby/cflat/asm/Register.java
* net/loveruby/cflat/platform/X86Linux.java ->
net/loveruby/cflat/sysdep/x86
* net/loveruby/cflat/compiler/CodeGenerator.java ->
net/loveruby/cflat/sysdep/x86
* net/loveruby/cflat/platform/Platform.java ->
net/loveruby/cflat/compiler
* net/loveruby/cflat/sysdep/x86/Register.java: new file.
* net/loveruby/cflat/compiler/Options.java: new method
#codeGenerator.
* net/loveruby/cflat/compiler/Compiler.java: get CodeGenerator
from Options.
* net/loveruby/cflat/compiler/CodeGeneratorOptions.java: make
public.
* net/loveruby/cflat/ir/IR.java: now naturalType is useless
(provided by CodeGenerator).
Sun May 10 20:24:13 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/asm/Assembler.java -> AssemblyFile.java
* net/loveruby/cflat/utils/AsmUtils.java: split #align from
AssemblyFile.
* net/loveruby/cflat/type/StructType.java: use it.
* net/loveruby/cflat/type/UnionType.java: use it.
* net/loveruby/cflat/platform: new package to extract platform
dependent operations.
* net/loveruby/cflat/compiler/Compiler.java: use it.
* net/loveruby/cflat/compiler/CodeGenerator.java: use it.
* net/loveruby/cflat/compiler/Options.java: provide Platform
object.
Thu May 7 13:00:09 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: should not return
Expr for stmt, to suppress wrong warning.
Thu May 7 12:55:41 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java (AddressNode):
always omit Addr for #shouldEvaluatedToAddress node.
Thu May 7 11:06:48 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java (BinaryOpNode):
evaluate RIGHT before LEFT.
Thu May 7 10:31:12 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: fix compile error.
Thu May 7 10:01:41 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: emit statement
info for casted stmt.
Thu May 7 10:00:38 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/ir/Dumper.java (printMember): simplify Label
dump.
Wed May 6 18:41:06 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: assignBeforeStmt
is useless. Use assign instead.
* net/loveruby/cflat/compiler/IRGenerator.java: should be able to
create tmp in variable initializers for also function toplevel
block.
* net/loveruby/cflat/compiler/IRGenerator.java: move funcall
before stmt.
* net/loveruby/cflat/compiler/CodeGenerator.java: do not display
"(null)" location.
Wed May 6 17:08:40 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/CodeGenerator.java: refactoring:
rename variables.
Wed May 6 15:50:22 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/asm/Type.java: types should not know signed
or not.
* net/loveruby/cflat/ir/Op.java: have signed/unsigned information.
* net/loveruby/cflat/compiler/IRGenerator.java: use new op and
type.
* net/loveruby/cflat/compiler/CodeGenerator.java: ditto.
* net/loveruby/cflat/compiler/TypeChecker.java (FuncallNode):
should check optional argument types.
* net/loveruby/cflat/compiler/CodeGenerator.java: now use simple
mov to load values from memory (and cast it later).
* net/loveruby/cflat/type/TypeTable.java: provide stack value
type.
Wed May 6 14:54:27 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/IRGenerator.java: isStatement() did
not work correctly; e.g. return ++argc failed to return value,
because ++argc was wrongly judged as statemen (is really expr).
Wed May 6 14:19:12 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/ir/StringValue.java -> Str.java
* net/loveruby/cflat/ir/IntValue.java -> Int.java
* net/loveruby/cflat/ir/IRVisitor.java: ditto.
* net/loveruby/cflat/compiler/IRGenerator.java: ditto.
* net/loveruby/cflat/compiler/CodeGenerator.java: ditto.
Mon May 4 19:00:33 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/LocalResolver.java: create
ToplevelScope, ConstantTable here (instead of creating them in
AST).
* net/loveruby/cflat/ast/AST.java: do not create ToplevelScope,
ConstantTable by myself.
Sun May 3 22:17:57 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java: new method dumpExpr
to dump single expression.
* net/loveruby/cflat/compiler/CompilerMode.java: add enum value
DumpExpr: define new option --dump-expr.
Sun May 3 19:08:07 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/parser/Parser.jj: sizeof TYPE requires one
more lookahead because EXPR of "sizeof EXPR" may have parentheses,
too. We can distinguish type and expr by 1 look ahead, because
Head of type() == head of typeref() == head of typeref_base().
typeref_base has unique terminal on head.
Sat May 2 09:49:23 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java: refactoring: rename
constant: programId -> ProgramName.
* net/loveruby/cflat/compiler/Options.java: ditto.
Sat May 2 09:30:51 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/Compiler.java (commandMain):
refactoring: extract method: #buildTarget.
Thu Apr 30 22:53:10 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/compiler/CodeGenerator.java: remove unused
method #doesSpillDX.
* net/loveruby/cflat/compiler/CodeGenerator.java: add "left"
argument to #compileBinaryOp.
Thu Apr 30 22:19:12 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/ast/ConstantTable.java: move under entity/.
* net/loveruby/cflat/ast/ConstantEntry.java: ditto.
* net/loveruby/cflat/compiler/CodeGenerator.java: follow it.
* net/loveruby/cflat/ast/StringLiteralNode.java: follow it.
* net/loveruby/cflat/ir/StringValue.java: follow it.
* net/loveruby/cflat/ir/IR.java: follow it.
Thu Apr 30 22:04:07 2009 Minero Aoki <[email protected]>
* net/loveruby/cflat/ast/AbstractAssignNode.java: remove unused