Wolfgang (Blub) Bumiller
|
baf6d3ead4
|
fixing ast_binstore_codegen's lvalue flag setting, now += on entfields works correctly
|
2012-08-14 17:35:02 +02:00 |
|
Wolfgang (Blub) Bumiller
|
65fb4b34b5
|
type comparison, function prototypes
|
2012-08-14 14:14:56 +02:00 |
|
Wolfgang (Blub) Bumiller
|
722be55fa9
|
removing all direct 'printfs' from ast and ir, replaced by the error interface
|
2012-08-14 13:14:32 +02:00 |
|
Wolfgang (Blub) Bumiller
|
cfdf915b25
|
ast_binstore, used for +=, -=, ++, -- etc
|
2012-08-14 10:40:48 +02:00 |
|
Wolfgang (Blub) Bumiller
|
3fd7a64b45
|
storing generated values and returning them early if they exist - will error when that doesn't make sense eg when trying to call codegen ast_ifthen more than once
|
2012-08-13 19:54:53 +02:00 |
|
Wolfgang (Blub) Bumiller
|
862b506dcd
|
initialize ast_expression_common.outl/outr
|
2012-08-13 19:40:06 +02:00 |
|
Wolfgang (Blub) Bumiller
|
fc7d32a715
|
fixed: ast_member needs to allow type_vector instead of type_float as base
|
2012-08-12 11:39:43 +02:00 |
|
Wolfgang (Blub) Bumiller
|
028543db8c
|
ast_binary now keeps track of types
|
2012-08-12 11:36:28 +02:00 |
|
Wolfgang (Blub) Bumiller
|
56c23dc11e
|
ast_member_new now fixed up for fields, ast_shallow_type added for creation of a type-only ast_expression
|
2012-08-11 22:14:16 +02:00 |
|
Wolfgang (Blub) Bumiller
|
91e3765a00
|
Generating fields using ir_builder_create_field
|
2012-08-11 18:05:56 +02:00 |
|
Wolfgang (Blub) Bumiller
|
f51ad96620
|
removing an unused variable
|
2012-08-11 15:41:37 +02:00 |
|
Wolfgang (Blub) Bumiller
|
9c2e6a2334
|
Experimental ast_member to access vector members
|
2012-08-08 14:49:37 +02:00 |
|
Wolfgang Bumiller
|
47a8a69f1c
|
ast nodes now store their type id, and can be checked via ast_istype
|
2012-07-29 10:03:13 +02:00 |
|
Wolfgang Bumiller
|
c5ba27da6f
|
ast_store to take ast_expression on its left, rather than ast_value. Assigning to a vector member would not put an ast_value on the left, but an ast_member, thus: ast_expression now already
|
2012-07-28 18:13:12 +02:00 |
|
Wolfgang Bumiller
|
2674982854
|
Moving parameters to from ast_value to ast_expression_common, it's part of the type after all
|
2012-07-27 15:22:39 +02:00 |
|
Wolfgang Bumiller
|
ab11808208
|
ast_block_set_type
|
2012-07-27 13:39:58 +02:00 |
|
Wolfgang Bumiller
|
1f8ece7f20
|
ast_return_new doesn't take an operator, we use INSTR_RETURN always, never INSTR_DONE for explicit returns
|
2012-07-26 23:23:47 +02:00 |
|
Wolfgang Bumiller
|
31ba1ec6c1
|
ast_return
|
2012-07-26 21:18:39 +02:00 |
|
Wolfgang Bumiller
|
e22d340e23
|
ast/ir support for unary instructions
|
2012-07-26 20:45:18 +02:00 |
|
Wolfgang Bumiller
|
4255b143b0
|
Removed params from ast_function again. It really is superfluous to copy them, just generate them from its ast_value's param list
|
2012-07-22 12:35:10 +02:00 |
|
Wolfgang Bumiller
|
d4c408b4bd
|
fix a warning about a format string
|
2012-07-22 12:22:25 +02:00 |
|
Wolfgang Bumiller
|
a4617d0e61
|
ast_function generates parameter locals, ir_function_create_local now allows adding parameters as long as no local variables have been added yet
|
2012-07-22 12:15:48 +02:00 |
|
Wolfgang Bumiller
|
43897f6e8f
|
store_param storetype, parameter value list added to ast_function
|
2012-07-22 12:07:30 +02:00 |
|
Wolfgang Bumiller
|
fec07921a4
|
removing params vector from ast_function, params are stored in its ast_value only
|
2012-07-19 18:14:08 +02:00 |
|
Wolfgang Bumiller
|
3987509493
|
Do not actually return after generating a call, there are other isntructions following
|
2012-07-04 15:16:02 +02:00 |
|
Wolfgang Bumiller
|
001420a7ef
|
Storing ir_v for functions
|
2012-07-04 15:00:30 +02:00 |
|
Wolfgang Bumiller
|
d259e75dc4
|
ast_call needs to set its func member
|
2012-07-04 14:41:39 +02:00 |
|
Wolfgang Bumiller
|
812084ad72
|
ast_call's param vector functions
|
2012-07-04 14:39:58 +02:00 |
|
Wolfgang Bumiller
|
6bbcd5a343
|
ast-macros: MKCONSTSTRING, added sHello hello world string
|
2012-07-04 14:20:54 +02:00 |
|
Wolfgang Bumiller
|
ed24ea0cef
|
creating and generating builtin functions, ast-macros for builtins, todo: params
|
2012-07-03 23:38:38 +02:00 |
|
Wolfgang (Blub) Bumiller
|
c1ea9cc409
|
function in the ast now MUST have an output type in their 'next' ast_expression pointer, the IR's outtype of functions is now filled
|
2012-06-29 13:07:19 +02:00 |
|
Wolfgang (Blub) Bumiller
|
67fa4ce07b
|
ir_builder_create_call to take return type from the ir_value
|
2012-06-29 12:55:35 +02:00 |
|
Wolfgang (Blub) Bumiller
|
01b3f5ef58
|
ast_call_codegen, ir_block_create_call plus call-related functions, ir_value->outtype TODO: fill outtype in ir_value
|
2012-06-28 17:21:26 +02:00 |
|
Wolfgang (Blub) Bumiller
|
e934e77cc5
|
ast_call node; codegen dummy
|
2012-06-28 16:15:51 +02:00 |
|
Wolfgang (Blub) Bumiller
|
f61d4331fe
|
Fixing NULL->false and empty lines...
|
2012-06-11 19:25:21 +02:00 |
|
Dale Weiler
|
2929eb39a8
|
fixed -Wconditional-uninitialized for ast codegen
|
2012-06-07 11:12:12 -04:00 |
|
Dale Weiler
|
f4bc6ba08a
|
Removed even more warnings
|
2012-06-07 11:09:29 -04:00 |
|
Wolfgang (Blub) Bumiller
|
200b425db0
|
Fixed some dangling '}', it compiles again now
|
2012-05-04 12:26:24 +02:00 |
|
Wolfgang (Blub) Bumiller
|
73749db6b4
|
What was I thinking... fixing loop's jump creation so it doesn't try creating multiple jumps... this code is also much more readable
|
2012-05-04 12:24:44 +02:00 |
|
Wolfgang (Blub) Bumiller
|
c670a8d278
|
ast_loop must end by entering the outgoing block
|
2012-05-04 12:01:53 +02:00 |
|
Wolfgang (Blub) Bumiller
|
2f92dedb4c
|
Move the output block of a loop to after the loop, otherwise IR dumps looks just messy... note that this is merely a cosmetic change
|
2012-05-04 10:01:38 +02:00 |
|
Wolfgang (Blub) Bumiller
|
c3460c1654
|
ast_function gets 'breakblock' and 'continueblock' for break and continue support; fixed some typos; added huge ast_loop_codegen implementation... need to go through it and check
|
2012-05-04 00:16:51 +02:00 |
|
Wolfgang (Blub) Bumiller
|
a1a9fc797d
|
Same for ternary: reordered a bit, and fixing ontrue->onfalse at the jump back to the merge block
|
2012-05-03 22:07:58 +02:00 |
|
Wolfgang (Blub) Bumiller
|
8a543bfae1
|
reorder ifthen codegen and fix a jump generation where I used ontrue instead of onfalse
|
2012-05-03 22:05:20 +02:00 |
|
Wolfgang (Blub) Bumiller
|
375cfd24b3
|
ast_loop - codegen dummied
|
2012-05-03 21:57:13 +02:00 |
|
Wolfgang (Blub) Bumiller
|
3e974a1a24
|
If-protect on_true and on_false in ast_ifthen since they can be NULL (contrary to ast_ternary where they can't)
|
2012-05-03 21:56:05 +02:00 |
|
Wolfgang (Blub) Bumiller
|
46122235e6
|
ast_function_codegen: Add a return instruction if it is missing, or error if we're not in a void-function
|
2012-05-03 14:15:02 +02:00 |
|
Wolfgang (Blub) Bumiller
|
0f023bc219
|
sprintf with length modifiers is annoying...
|
2012-05-03 13:45:24 +02:00 |
|
Wolfgang (Blub) Bumiller
|
4c9c6ee5bd
|
ast_ternary_codegen - beware, it's almost a spaghetti... almost...
|
2012-05-03 13:02:29 +02:00 |
|
Wolfgang (Blub) Bumiller
|
91bf040f0a
|
ast_function_label now takes a labelname to prefix the id with
|
2012-05-03 12:40:49 +02:00 |
|