Goose  Timeline

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

197 check-ins using file bs/eir/tostring.h version c0b126cac8

2024-09-13
21:05
Drop in the most apocalyptic changes: new CIR instruction structure, new sequence builder, new compile time address representation, do almost just the bare minimum to compile again. A few simple things are still working somehow check-in: 57d4d0c79e user: achavasse tags: cir-ssa-refactor
2024-08-31
14:05
Refactor Instruction to be just a variant instead of a class containing a variant and a clownshoes bunch of constructors check-in: 8ffbc35112 user: achavasse tags: cir-ssa-refactor
13:11
Add missing file check-in: 9fcc77a4fa user: achavasse tags: cir-ssa-refactor
13:00
Update to clang 18, pull some of the deps automatically when configuring check-in: 6f52a8bfa3 user: zlodo tags: cir-ssa-refactor
2024-04-09
22:55
Here we go again. Life is pain. Life is suffering check-in: 99c630bf0a user: zlodo tags: cir-ssa-refactor
2024-03-30
08:58
structs:
  • diagnose member name collisions
  • add tests for the dot operator
  • fix dot operator
Leaf check-in: f7de54375b user: zlodo tags: trunk
2024-03-23
12:47
structs:
  • add test for nested initialization
  • fix nested initialization
check-in: ea17da4e19 user: zlodo tags: trunk
2024-03-14
23:23
  • add type wrapper for unresolved compile time identifier, move undefined identifier handling to dropValue() of those
  • implemented dot operator for structs
  • fixed struct lazy parsing
  • implemented some tests for structs default construction
  • fixed struct default ctor generation
check-in: 75a719c020 user: zlodo tags: trunk
2024-02-09
18:05
Lowering: completely reworked all lowering to happen in the same two unified extension points upstream of all three CIR consumers check-in: 1793989d05 user: zlodo tags: trunk
2024-01-03
22:20
Added _LowerType extension point, called to decide what type to use when allocating locvars check-in: 11b6bc7f84 user: zlodo tags: trunk
2024-01-02
22:41
Structs: build the default ctor and add it as an overload of _Initialize. check-in: ad919df201 user: zlodo tags: trunk
2024-01-01
23:23
Structs: build the underlying tuple type in finalize() check-in: 7bf7fc54a6 user: zlodo tags: trunk
2023-12-30
21:58
Structs: invoke initialize upon creating a member variable (for the default ctor) check-in: f47d37b2d5 user: zlodo tags: trunk
2023-12-28
13:57
Structs: inside of the struct's scope, materialize member variables as refs (so they can be used in the initialization expressions for following member variables declarations) check-in: 8647b9c619 user: zlodo tags: trunk
2023-12-26
15:41
Structs: add the Finalize extension point that finalizes the creation of a struct after gathering its content. check-in: f1458583b5 user: zlodo tags: trunk
2023-12-16
00:02
Struct builder: gather var members check-in: bce164db61 user: zlodo tags: trunk
2023-12-14
23:30
Structs: perform lazy parsing when a struct type is used. check-in: 4ea0bba9a7 user: zlodo tags: trunk
2023-12-11
00:08
Move the local type inference code out of locvar and into its own function so it can be reused for struct members check-in: 1f1faa7fe2 user: zlodo tags: trunk
2023-12-09
19:56
Remove some dead code. check-in: f99a469d36 user: zlodo tags: trunk
19:44
Assigning something to a Decl or a TNamedDecl no longer directly declares a variable but creates an intermediate DeclWithInit or TNamedDeclWithInit, which declare variables when dropped. check-in: 308bd3ed4d user: zlodo tags: trunk
2023-12-08
21:16
Some work on struct builder check-in: ae07ee4400 user: zlodo tags: trunk
2023-12-06
20:49
Begin implementing structs. check-in: 973848d259 user: zlodo tags: trunk
2023-12-05
18:43
  • Comptime functions are now explicitely marked with "comptime"
  • Fixed some bugs (or added placeholders) for things that the above change revealed to be broken or missing
check-in: d6abaa6734 user: zlodo tags: trunk
2023-11-30
18:29
Handful of fixes and improvements from an abandoned refactor of inline funcs, will go for a different solution check-in: 5b069c9677 user: zlodo tags: trunk
2023-11-08
21:45
  • add codegen and verification tests for inline funcs
  • remove the awkward llvm basic block pointer from CIR basic block
check-in: b3e7f71393 user: zlodo tags: trunk
2023-11-05
13:11
  • Remove an obsolete TODO
  • Remove hackish verification helper functions that won't be needed now that we have proper inline functions
check-in: 6369c5a368 user: zlodo tags: trunk
13:04
Implemented inline functions check-in: 96c02f37d1 user: zlodo tags: trunk
2023-10-05
00:14
Removed the work queue and implemented a proper dependency manager with callbacks check-in: 0e7409855c user: zlodo tags: trunk
2023-09-21
18:08
  • Add a compilation state to func CIR to prepare for inline funcs
  • Add a job queue to defer some compilation jobs
  • Refactor LocationId to store an actual location for poison values to help with debugging
check-in: e24e9bfad5 user: zlodo tags: trunk
2023-08-28
20:36
  • Removed old, obsolete, unused cir::Decorator
  • Implemented a CFG inliner function
check-in: 44c339148f user: zlodo tags: trunk
2023-08-27
22:30
  • Added "CallCheck" CIR instruction to request the verifier to check a bunch of func params like it was a real call
  • Used the above to verify the arguments passed to ghost funcs
check-in: 83971c96a4 user: zlodo tags: trunk
21:13
Interpreter: simplify handling of temporaries check-in: 3fbe5ad303 user: zlodo tags: trunk
2023-08-25
18:44
Some cleanup in preparation for getting rid of proposition lists check-in: f605c7c4a3 user: zlodo tags: trunk
2023-08-24
21:55
Verifier: optimize the way CreateTemporary/GetTemporary are handled check-in: 942f3c4fe0 user: zlodo tags: trunk
2023-08-21
17:33
Refactor CompileFunc to untangle things a bit check-in: ecc62fe531 user: zlodo tags: trunk
2023-08-18
18:40
Added helper functions to bind parameters to a proposition list and append its content to a basic block check-in: fc3d788320 user: zlodo tags: trunk
2023-08-13
18:23
forall statement: factorise out the bracket block parsing check-in: 890f3f7581 user: zlodo tags: trunk
18:04
It turns out cmake hadn't, in fact, failed me for the last time: migrating back from meson to cmake check-in: 9722f7aa3f user: zlodo tags: trunk
2023-08-02
22:14
Update mimalloc and Catch check-in: 9ee0c01395 user: zlodo tags: trunk
21:46
Implemented forall statement check-in: 32f94cd2e1 user: zlodo tags: trunk
2023-07-22
17:26
Add zstd dependency (some versions of the lld libs need it now) check-in: e4bae45a24 user: zlodo tags: trunk
2023-07-15
19:25
Fixed values not being destroyed when a lifetime scope ends check-in: 9a57f2204f user: zlodo tags: trunk
2023-07-13
21:45
CIR, verifier: added forall quantified variables check-in: 20223acc66 user: zlodo tags: trunk
2023-07-06
23:03
Implemented "IsPrefixOf" intrinsic function. check-in: 045e459cb4 user: zlodo tags: trunk
18:25
Verification: add IsPrefixOf instruction check-in: 33d8f4d593 user: zlodo tags: trunk
2023-07-05
22:01
Some builtins to work with references during verification:
  • RefToAddr conversion function
  • dot operator overloads to extract the lifetime, origin and path of an address
check-in: 914b2e2af1 user: zlodo tags: trunk
2023-07-01
11:21
Execute: function argument passing simplification (overlooked from back when the CIR was turned into a stack language) check-in: 2e14edebd0 user: zlodo tags: trunk
2023-06-30
22:41
Verifier:
  • Remove hardcoded handling of ref type from verifier, lower ref type to address for verification instead
  • Complete the handling of address type and handle selecting+loading an address' lifetime, origin and path
check-in: 1adbcaa805 user: zlodo tags: trunk
2023-06-22
23:33
Implemented lowering of Addresses into a tuple representation for verification check-in: 25b51220ed user: zlodo tags: trunk
2023-06-17
10:15
  • Remove MemLoc, it's redundant with cir::Address
  • Added compîlation time sequence type
  • Partially handle sequence type in the verifier (to be completed later)
  • Added "SelectPath" builtin type for adress paths
check-in: 08898dae70 user: zlodo tags: trunk
2023-05-31
21:34
Lifetimes: implemented verifier's z3 representation check-in: b1d4853b7f user: zlodo tags: trunk
2023-05-05
18:03
Lifetime specifications parsing check-in: bb7e75cb1b user: zlodo tags: trunk
2023-04-03
22:37
Moved the code that emits type predicate checks for values returned by intrinsics into an extension point check-in: 72cb3ae97a user: zlodo tags: trunk
2023-03-28
19:44
Get rid of the TCRINFOS macro, use std::source_location instead to remove some noise check-in: d9414ddc6f user: zlodo tags: trunk
2023-03-27
18:34
  • reworked value wrapping in intrinsics, unwrapping can now only happen for the returned value (for verification reasons)
  • removed the _ConvertFuncArg extension point, replaced it with _ConvertFuncArgs that operates on all of the args (so that we can do cross argument things in the prelude, will be needed for lifetimes)
check-in: f271454617 user: zlodo tags: trunk
2023-03-06
22:24
prelude: implemented UnwrapValue check-in: c550a4bc43 user: zlodo tags: trunk
2023-03-05
22:24
  • removed fmtlib, now use std::format
  • vastly improved the overload resolution debugging tools
  • prelude: started adding some extra error detection for small things that don't need to be builtin
  • prelude: started working on implementing #for for tuples, some stuff needs to be addressed still
  • fixed some type checking issue with wrapped args
  • fixed superfluous nested lifetime scope in brace blocks (which caused redundant calls to some extension points)
check-in: 4d4d76607a user: zlodo tags: trunk
2023-02-28
00:55
  • Intrinsic functions: no longer systematically wrap every argument. Instead, arguments that needs to be wrapped can be indicated by decorating their type with the WrappedArg type function.
  • Fixed several bugs related to forwarding template vars ($$whatever)
check-in: 9f242fb2ff user: zlodo tags: trunk
2023-02-20
17:54
Migrated to clang16/llvm16. Created a shitty layer on top of llvm to cope with losing the pointee types from llvm pointer types (which are now opaques). It was a huge pain in the ass. check-in: 0c646816e4 user: zlodo tags: trunk
2023-02-07
15:49
Removed the ToType extension point, go through typechecking instead for converting things such as tuple of types into types. This is more generic than the previous approach and will avoid some pitfalls in the future. check-in: 1b18849f5c user: zlodo tags: trunk
2023-01-30
19:33
Implemented the _IsTrivialInitialization extension point to optimize tuple initialization in the same way as assignments check-in: d70fa1ef12 user: zlodo tags: trunk
2023-01-29
20:48
  • Added the _IsTrivialAssignment extension point to indicate whether an assignment between two given types is trivial or absolutely needs to be resolved to an operator_assign invocation
  • Use the above to simplify tuple assignments when all the contained members have trivial assignments
check-in: 7751ce994d user: zlodo tags: trunk
2023-01-24
18:02
  • Refactored tuple assignment operator and fixed a case where it would crash
  • Fixed incorrect CIR code generation involving constant tuples containing computed values
check-in: b47efa975d user: zlodo tags: trunk
2023-01-10
22:29
ToString: don't print addresses of void pointers anymore check-in: c8f5e99651 user: zlodo tags: trunk
22:01
Implemented textual dump of a function's CIR to more easily inspect it and implement some code generation tests at the CIR level check-in: 4edae7e1a3 user: zlodo tags: trunk
2023-01-09
19:06
Fixed bad hashing implementation of terms containing a locationId that caused some absurd crash in the verifier check-in: 8fd3b7a078 user: zlodo tags: trunk
2023-01-06
19:13
Remove redundant calls to the ToType extension point when compiling function bodies check-in: 78a358141d user: zlodo tags: trunk
2023-01-05
19:44
Fixed passing tuple by value to functions, which involved properly handling type checking of constant tuples containing computed data and some codegen bugs check-in: 9b8306c3af user: zlodo tags: trunk
2022-11-21
18:59
  • some fixes in #for base implementation
  • g0api: exposed functions to deconstructs decls
check-in: ac0c5a2c6a user: zlodo tags: trunk
2022-11-20
10:49
g0api: expose some tuple and some parsing stuff check-in: ec453bb5a1 user: zlodo tags: trunk
2022-11-17
22:57
Remove an old z3 workaround that doesn't seem necessary anymore check-in: 44da39ac61 user: zlodo tags: trunk
22:43
g0api:
  • visiblity scopes
  • combined visibility/lifetime scopes
check-in: 8546f1ef75 user: zlodo tags: trunk
00:46
expose more compiler functionality to g0api:
  • local variable declarations
  • lifetime scopes
check-in: 605ff0a654 user: zlodo tags: trunk
2022-11-11
20:01
  • Implemented template tuples and vararg tuples
  • Fixed a few issues with the verifier
check-in: 08ffdaf6db user: zlodo tags: trunk
2022-09-02
21:42
  • Implemented a test for variadic functions
  • Fixed a million issues and missing things preventing the above from working
  • Implemented equality operators for types
check-in: 373a6ebd57 user: zlodo tags: trunk
2022-08-29
20:42
Partial implementation of compile-time for loop (rest to be done in prelude but needs a handful additional apis) check-in: 24b6c5ae2e user: zlodo tags: trunk
2022-08-28
17:12
vararg templates: completed the pack TExpr and pack TVars implementations (need tests) check-in: 0146622968 user: zlodo tags: trunk
2022-07-30
11:41
varargs: simplify (not going to attempt handling nesting repetitions after all) check-in: 4c0f447d59 user: zlodo tags: trunk
2022-07-25
17:23
vararg templates: set the signature of pack texprs as the repeating part of the vector, and diagnose packs not appearing last check-in: 27cf09cdf5 user: zlodo tags: trunk
2022-07-22
00:36
Switch back to using fmtlib so we can build with clang 14 for stability and since nowadays we apparently can't expect to be able to use c++ features that were accepted in the standard 2 years ago :/ check-in: 7e6d3483ec user: zlodo tags: trunk
2022-07-21
01:09
Small cleanup check-in: 6e0a90698d user: zlodo tags: trunk
2022-07-20
19:22
vararg template: added pack TExpr and ellipsis operator check-in: ba07901758 user: zlodo tags: trunk
2022-07-18
23:45
vararg templates: added a "prepare template" step prior to generating the template signature, which does nothing yet check-in: fe34bd71de user: zlodo tags: trunk
00:14
Keep track of the repetition depth of pack TVars, and assign a new value index for each repetition of a pack hole check-in: a2a6841c8b user: zlodo tags: trunk
2022-07-17
10:51
Fixed a bug in the verification instruction filter that somehow resulted in failed tests only on mac check-in: 64463a60a6 user: zlodo tags: trunk
2022-07-16
14:42
Varargs: added a "nested repetition depth" property to holes check-in: 97ff23912a user: zlodo tags: trunk
2022-07-05
22:10
TypeChecking: keep track of nested repetition indices for each sub context check-in: 95bdac72ca user: zlodo tags: trunk
2022-07-04
21:48
Minor cleanup check-in: 29b4ebb32f user: zlodo tags: trunk
21:20
typechecking: refactor type checking context to be able to hold more sub-context information than hole namespace indices check-in: 9fd8a2a87e user: zlodo tags: trunk
17:45
Refactored some template rules and type checking rules to avoid calling BuildTemplateSignature from inside type checking rules check-in: 64224a915f user: zlodo tags: trunk
2022-07-02
14:22
Vararg templates: function param decls with open tuple types are expanded into multiple params check-in: ecd5b0e89a user: zlodo tags: trunk
2022-06-30
19:06
Remove obsolete TODO check-in: 3f5776378b user: zlodo tags: trunk
17:58
Verifier: fix unique id generation to be done on a per function basis rather than globally to make the z3 generation tests more stable check-in: f4e40b75d7 user: zlodo tags: trunk
2022-06-29
21:47
The CIR is no longer made out of instructions that are basically expression trees, but is now instead a stack language to make it possible to insert verification instructions before and after the evaluation of individual function arguments check-in: 1f87fbda15 user: zlodo tags: trunk
21:39
  • Verifier: consider verification failed if we encountered anything funny that prevented us from translating the entire function cfg to z3, rather than silently ignoring it
  • Verifier: fixed a case where the verifier would improperly bail out and do the above
  • Verifier: fixed a nasty use-after-free caused by forgetting an ampersand. fucking c++
Closed-Leaf check-in: 9814f18b04 user: zlodo tags: cir-stack-language
2022-06-28
22:51
Removed an unusued file and a left over debugging profanity check-in: 6c5b747f5c user: zlodo tags: cir-stack-language
22:23
codegen: improved the translation of address computations into llvm GEP instructions check-in: 2a03dd67e5 user: zlodo tags: cir-stack-language
2022-06-27
16:56
  • cir: allow verification specific code and instructions to be interspersed with regular code again and added a function to filter them out before consuming the code in the interpreter and during codegen
  • verification: better handling of non-representable types that don't involve giving up entirely on verifying the function
  • g0 api: updated it to match the CIR changes
  • prelude: adapted reference verification to the new CIR api
check-in: b81d4242e3 user: zlodo tags: cir-stack-language
2022-06-23
20:56
Ported most of the g0 api to the new CIR language check-in: 9eb48e68a1 user: zlodo tags: cir-stack-language
20:01
Correctly handle ghost func applications as "storage locations" alongside regular addresses, fixes the remaining ghost func test check-in: 68da32e88b user: zlodo tags: cir-stack-language
2022-06-22
20:06
Re-implemented "addr modified by loop" stuff (except ghost func related stuff) and re-enabled loop verification tests check-in: a0a57b5e22 user: zlodo tags: cir-stack-language
2022-06-21
17:26
Removed a bit of dead code check-in: b78a3ea203 user: zlodo tags: cir-stack-language
17:09
  • Implemented conversion of Address into a z3 expression, fixes ghostfunc test 4
  • Fixed handling of Ret terminator that didn't always pop the result value
check-in: d2090773d9 user: zlodo tags: cir-stack-language
2022-06-18
18:51
  • Added a location id to all CIR instructions (needed with the stack based approach to locate intermediate results)
  • Fixed a bunch of verifier errors
  • Re-enabled most verifier tests, other than some requiring to re-implement a few more bits
check-in: b4d5bdf6ec user: zlodo tags: cir-stack-language
2022-06-11
12:29
Verification now mostly works again, tests not re-enabled yet check-in: 17301ed8fc user: zlodo tags: cir-stack-language
2022-06-08
22:38
Refactored the verifier to use the stack-based CIR. It compiles but isn't re-enabled yet check-in: 4f05876cc2 user: zlodo tags: cir-stack-language
2022-05-28
17:17
Small optimization. check-in: f886c2d77c user: zlodo tags: cir-stack-language
2022-05-26
22:48
Merge mac build fixes from trunk check-in: 536a94f712 user: zlodo tags: cir-stack-language
22:42
Mac build fixes check-in: b8a2990900 user: zlodo tags: trunk
11:31
Re-enabled codegen and related tests, and adapted it to the now stack-based CIR language check-in: dd5c48041c user: zlodo tags: cir-stack-language
2022-05-25
17:28
  • Split function invocation code into several specialized versions for each function kind
  • Almost fully completed the migration of CIR to a stack language
  • Compilation-time execution works again
check-in: 7992dbe59f user: zlodo tags: cir-stack-language
2022-05-23
09:04
Added a CIR instruction to push a constant on the stack check-in: 0d0130b939 user: zlodo tags: cir-stack-language
08:44
  • CIR instructions are now stored in lists
  • Execute: handle the stack
  • Converted some instructions to use the stack
check-in: 0d5427d49b user: zlodo tags: cir-stack-language
2022-05-16
23:40
Temporarily disabled codegen, verification, and all the tests that can't work without these check-in: 5fc7b0623f user: zlodo tags: cir-stack-language
2022-05-15
19:25
cir: implemented a helper object to decorate operations such as calls with a prologue and an epilogue, not used yet. check-in: 2503738366 user: zlodo tags: trunk
2022-05-09
18:52
  • Verifier: implemented a new encoding for memory locations that lets the verifier deal correctly with aliasing
  • Implemented test for the above
  • Fixed a reference typechecking bug to celebrate a day ending in Y
check-in: ead7162820 user: zlodo tags: trunk
2022-05-02
10:42
Updated dependencies check-in: 17cf663ede user: zlodo tags: trunk
2022-04-04
23:20
  • Fixed incorrect argument types for z3 func decls
  • Fixed template ghost funcs
  • Encode address calculations into z3
  • Added a typechecking rule to unwrap references of references (which happen when we pass a variable containing a reference)
check-in: ef60c39ded user: zlodo tags: trunk
2022-03-25
18:42
Verifier: encode reference values address calculation into z3 expressions (for situations where they are used as values, rather than dereferenced) check-in: 0e33b524a6 user: zlodo tags: trunk
2022-03-15
22:54
Fix verification of loops that modify ghost func closures check-in: 6564792477 user: zlodo tags: trunk
2022-03-14
19:23
  • bracket blocks inlined in the code are no longer proposition lists but a new type of block to contain "ghost code" (ie a verification specific cfg)
  • added a GhostBranch instruction to insert the above in the middle of regular code
  • removed a bunch of hacks to ignore load/stores involving ghost funcs during execution and codegen since they are now separated from normal code using the above
  • miscellaneous other refactorings and improvements
  • as a result ghost code is now more flexible and can use idiomatic tuple assignments to exchange the values of two ghost function closures
check-in: 68260b65f2 user: zlodo tags: trunk
2022-03-11
19:08
Verifier: handle ct_int types and ct_int constants check-in: 9b10735b71 user: zlodo tags: trunk
2022-03-01
00:29
Ghost functions: added tests and fixed a lot of bugs, it even seems that all this garbage is actually beginning to work check-in: 09337f6de9 user: zlodo tags: trunk
2022-02-18
17:36
  • refactored function parsing so that ghost function declarations can actually work (ie they don't expect a function body)
  • some fixes in codegen to properly ignore statements involving ghost functions
check-in: 07963466bf user: zlodo tags: trunk
2022-02-14
17:42
verifier: handle setting and retrieving the value of ghost function closures check-in: bef38cb315 user: zlodo tags: trunk
2022-02-02
01:08
verifier: build and cache z3 declarations for ghost funcs check-in: e607197fe9 user: zlodo tags: trunk
2022-01-31
18:07
ghost func invocation generates the ghost call CIR instruction (only allowed inside of propositions) check-in: c55193554e user: zlodo tags: trunk
2022-01-29
13:41
ghost funcs: added GhostCall CIR instruction check-in: 802b9820d4 user: zlodo tags: trunk
13:12
ghost functions parsing: ignore following brace block if any, since they don't have bodies check-in: b60fb08f17 user: zlodo tags: trunk
2022-01-28
17:41
Ghost functions:
  • implemented "ghost" operator to mark a function or template function as ghost
  • template functions can now be ghosts
  • detect and reject mixing ghost and non ghost functions in the same overload set
check-in: 26c724e318 user: zlodo tags: trunk
2022-01-27
18:33
Verifier: factored some code out of value tracker check-in: 480aaf534c user: zlodo tags: trunk
2022-01-25
18:57
FuncType: replace flags with a "kind" enum, add ghost kind check-in: 55c2184e6f user: zlodo tags: trunk
2022-01-24
19:09
Verifier: factor out variable tracking out of the builder so it can be reused to track other kind of values check-in: 6aa3486a16 user: zlodo tags: trunk
2022-01-07
20:02
  • Use non-experimental std::coroutine
  • Get rid of fmt lib, use std::format instead
check-in: 3b954688f3 user: zlodo tags: trunk
01:25
Verifier: fix missing loop context in error messages in some cases check-in: 55688826d9 user: zlodo tags: trunk
00:59
  • Verifier: fixed some errors in the implementation of the k-induction loop verification, which was breaking in some cases with nested loops
  • Verifier: fixed some data flow bugs that resulted in losing track of the state of some local variables in some situations
check-in: 43f03d4856 user: zlodo tags: trunk
2021-12-09
18:31
Verifier graphviz vizualizer fixes and improvements check-in: 5a84c0610a user: zlodo tags: trunk
2021-12-08
20:05
Implemented a graphviz visualizer to help debugging the loop verifier check-in: 12fc470a72 user: zlodo tags: trunk
2021-11-28
13:34
Verification: fixed incorrect handling of type predicates in function parameters check-in: c066339928 user: zlodo tags: trunk
2021-11-26
22:42
  • Fixed adding predicates to a type alias created with using that modified the original type
  • Fixed ambiguous parsing of using expressions that were mistook for overload redefinitions in some cases
check-in: 35ff2a536e user: zlodo tags: trunk
00:37
  • Parser: if an infix rules fails to parse, backtrack
  • Parser: it is now possible to define a contextual "default lhs value"
  • Parser: if an infix operator fails parsing, it is retried as an infix operator, using the default lhs value if there is one available
  • Type predicates: setup @val as the default lhs value inside of the proposition list context, so it is now possible to write u32[<10] instead of u32[@val<10]
check-in: 0184a27429 user: zlodo tags: trunk
2021-11-25
21:21
Got rid of the where operator. Predicates are now added to types simply by following the type with a proposition list. check-in: 23ecb4f9cb user: zlodo tags: trunk
20:30
  • simplified ref parsing implementation by using the parser's infix parsing rule helper
  • refactored "requires" and "ensures": they are now simply infix operators that take a function type on the lhs and a proposition list on the rhs
check-in: e1ede8dafa user: zlodo tags: trunk
2021-11-24
19:45
Propositions are now parsed like regular statement sequences, but using the proposition list under construction as the current builder check-in: 8be0ff932c user: zlodo tags: trunk
00:38
Removed a misleading comment check-in: ea3608d6e9 user: zlodo tags: trunk
00:03
  • Moved the hackish "cast" function from builtins to the prologue
  • Fixed failed eager evaluation of builtin function calls raising erorrs, instead of being ignored
  • Fixed the first local variable inside intrinsic functions getting a temporary index that aliases one of the params to hilarious effects
check-in: b8498ed590 user: zlodo tags: trunk
2021-11-23
19:45
  • Parser: when encountering a prefix bracket block, parse it into a propositions list.
  • Builtins: when a proposition list is dropped (ie used as a stand alone statement), convert it into assert instructions.
  • Builtins: remove the builtin assert function, now replaced with the above so that propositions are always enclosed in brackets, regardless of where they are used. Also removes the confusion of making the assert function a compile-time check when its traditionally a runtime check
check-in: 2ba2e560b1 user: zlodo tags: trunk
2021-11-22
20:33
Parser: split block parsing code check-in: a4eaf901ef user: zlodo tags: trunk
20:22
Function pre-conditions and post-conditions now use the same proposition lists as type predicates check-in: 1c335aeb04 user: zlodo tags: trunk
2021-11-19
22:28
Replaced "TypePredicates" by a more generic "Propositions" class, to be used for function predicates as well check-in: 098b3c34c9 user: zlodo tags: trunk
2021-11-16
21:18
The details of creating a new visibility scope are now handled by the builder instead of being hardcoded in the parser check-in: 16dd587889 user: zlodo tags: trunk
2021-11-13
14:09
The builder is now passed as the first param of the _DropValue extension point check-in: c33b227735 user: zlodo tags: trunk
2021-11-11
20:31
Removed two other obsolete files check-in: ade3099696 user: zlodo tags: trunk
20:19
Removed a file that was not properly deleted in the previous commit check-in: b808c4a5f5 user: zlodo tags: trunk
20:05
Refactored the code builder: it is now carried around as a Value, and accessed through a bunch of extension points, so we can have different builders (and even user defined ones) later to make classes etc. check-in: 1ad61a2717 user: zlodo tags: trunk
01:00
  • refactored the ref syntax again: "ref" is now an infix operator that takes an "AccessLevel" compile time value (mut/const/temp) on the lhs, or a TVar to capture/constrain it
  • used the above feature to fix the constref verification _ConvertArg overload which was silently dereferencing the arg, causing it to get converted to a temp ref in all cases
check-in: d679acf746 user: zlodo tags: trunk
2021-11-05
12:56
Fixed non mutable reference passing verification. It was a completely stupid error entirely in the prelude. I'm already fucking up using my own language, this bode well check-in: 0c58009de2 user: zlodo tags: trunk
2021-11-03
22:55
  • References: ref now creates a template type accepting any kind of reference, and mut/const/temp are prefix operators turning that into a ref (or template ref) type of the corresponding kind (this also changes the syntax from ref mut XXX to mut ref XXX which is more natural)
  • Fixed the bizarely broken implicit referencing typechecking rule that performed a superfluous intermediate TypeCheck that crashed on non mutable template reference types
  • Fixed builtin function wrapper that omitted a cast of the return value to the specified type, which allowed builtin functions to silently return values of a different type than advertised, resulting in fun type checking errors
  • Fixed a bunch of fucked up return types that worked by chance (because of the above) in several g0 api functions
  • Implemented non mutable reference passing verification + related tests (it doesn't work yet but too many fixes need to be committed first)
check-in: 55994a469a user: zlodo tags: trunk
2021-11-01
11:16
Verifier: fixed verification taking a billion years in some cases check-in: ec2b1e3b74 user: zlodo tags: trunk
2021-10-31
18:52
  • Reverted most of the horribly complicated changes done since [b3ff9af3c2fe4925], other than the ability to hash all terms, values, instructions and predicates
  • Solved the problem for which tests were added in [b3ff9af3c2fe4925] in a much simpler way
check-in: 1fe5a1ac2b user: zlodo tags: trunk
2021-10-30
22:51
  • Fixed type predicate hashing
  • Template: create a monomorphization specific identity for verification (as opposed to the instance specific identity in which we ignore predicate hashes)
check-in: a681efadd9 user: zlodo tags: trunk
2021-10-29
20:03
Template rules: implemented a function to setup bindings for captured predicates check-in: eccb9be7b9 user: zlodo tags: trunk
2021-10-28
21:48
Template rules: implemented a function to extract the type predicate hashes of captured types check-in: 8fe613b1ac user: zlodo tags: trunk
20:25
Template: split template function verification from instantiation check-in: 84723188cd user: zlodo tags: trunk
2021-10-27
22:23
Func: CompileFunc() doesn't perform function verification anymore, there's now a separate CompileAndVerifyFunc() for that check-in: 562bf11329 user: zlodo tags: trunk
20:55
Parser: when building a function, if its parent identity depends on type predicates captured by template vars, build it as a template function instead. check-in: 45078c42df user: zlodo tags: trunk
2021-10-26
18:43
Type predicates: implemented helper functions to append / filter out type predicate hashes in identities. check-in: d40e6470bf user: zlodo tags: trunk
2021-10-25
19:34
Type predicates: store the expressions as an array of values, which avoids unecessary conversions and results in the inclusion of the CIR from the expressions in the hash check-in: 996d8d9686 user: zlodo tags: trunk
2021-10-24
20:22
Implemented CIR instruction hashing check-in: f5cd8d2642 user: zlodo tags: trunk
2021-10-23
19:40
Small code cleanup, moved some code to .cpp that didn't need to be in the header check-in: ef3548db6c user: zlodo tags: trunk
16:34
Implemented hashing of EIR terms check-in: ec41139b5a user: zlodo tags: trunk
2021-10-09
22:07
Prelude: use the Conjunction instruction to build the reference predicate equivalence check check-in: 233221b915 user: zlodo tags: trunk
21:50
Added the Conjunction CIR instruction to build a conjunction from predicates at verification time check-in: e3485faf08 user: zlodo tags: trunk
20:12
Predicates: add the possibility to store named sets of predicates in types, to be retrieved from a dictionary at verification time check-in: 459f60ca3a user: zlodo tags: trunk
15:52
  • Fixed a couple of verification bugs and added related tests
  • Added some tests for currently broken verification scenarios involving template functions
check-in: b3ff9af3c2 user: zlodo tags: trunk
2021-10-08
17:06
Linux build fix check-in: e386f21089 user: zlodo tags: trunk
2021-10-07
22:37
Added tests for mutref predicates equivalence checking check-in: 50c3984309 user: zlodo tags: trunk
2021-10-06
21:50
Mut ref predicates verification: display a useful error message check-in: 05ada78145 user: zlodo tags: trunk
14:13
Diagnostics: when registering a custom diagnostic message, save the context stack along with it check-in: 18734ccbef user: zlodo tags: trunk
2021-10-04
16:13
Fixed build issues with Tracy on mac and updated it to the last version check-in: f408a2e123 user: zlodo tags: trunk
12:06
Cleanup check-in: b974d30199 user: zlodo tags: trunk
11:57
  • Fixed assignment of tuples whose content is not known at compile time
  • templates: fixed forwarding TVars not retrieving their bound value
  • g0 api: fixed type predicates retrieval
  • Prelude: implemented a first rough version of predicate type checking when passing mutable references to functions
check-in: 2de6fd1212 user: zlodo tags: trunk
2021-10-01
19:20
  • improved diagnostics for ambiguous typechecking rules
  • fixed quote type checking rules
  • fixed linux target compilation
check-in: a31d09af08 user: zlodo tags: trunk
2021-09-30
23:37
Fixed a couple of bugs, but the linux version is broken for now (due to language bugs that can't be worked around and need to be fixed) check-in: 24415e41e4 user: zlodo tags: trunk
22:07
Correctly generate and link executables on darwin check-in: 5f6197d1a0 user: zlodo tags: trunk
19:14
Added a builtin g0 variable that exposes the name of the target OS, just to be able to quickly hack around some rudimentary mac support check-in: ec5428614c user: zlodo tags: trunk
2021-09-29
22:59
Fixes for wsl build check-in: 886e9f72c4 user: zlodo tags: trunk
22:07
  • fix stringid static members
  • fix build and crashes on mac
check-in: 2f7a76dded user: zlodo tags: trunk
2021-09-28
17:59
Fix functions and template functions not getting compiled with visibility over their original enclosing scope, but over the current scope at the point of invocation instead check-in: 39c8a653da user: achavasse tags: trunk
2021-09-26
23:25
Fixed template bugs with parametric types check-in: 097569fdd6 user: achavasse tags: trunk
21:11
TDecl: instead of directly storing the type signature (and forgetting all about the nested TExprs), we store the TExpr and generate the signature during typechecking check-in: 00408e8723 user: achavasse tags: trunk
19:47
  • Fixed a handful of parsing issues related to templates
  • Added missing export of "ref" to g1
check-in: 93eaca4c2b user: achavasse tags: trunk
17:00
g0 api: added a function to retrieve the CFG from a code builder check-in: e1194caa9e user: achavasse tags: trunk
16:16
g0 api: removed the old codegen module wrapper, use TypeWrapper instead check-in: ded246dccd user: achavasse tags: trunk
14:17
Intrinsics: expose the current code builder as an implicit parameter check-in: 60a2f901d5 user: achavasse tags: trunk
13:03
Integrated mimalloc check-in: 8398bd36c2 user: achavasse tags: trunk
12:00
  • Fixed TypeType's representation. Declaring a type, non-template parameter (for compile time functions) now works
  • Removed the trie comparison algorithm from eir that was never used
  • Misc code cleanup
check-in: 21f907a13f user: achavasse tags: trunk