generated from amazon-archives/__template_Apache-2.0
-
Notifications
You must be signed in to change notification settings - Fork 26
Add a resolution phase to Laurel #501
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
97 commits
Select commit
Hold shift + click to select a range
241c598
Introduce pure property for procedures
keyboardDrummer 079f5da
Rename
keyboardDrummer 4a9dad2
Add additinal tests
keyboardDrummer 6b2d31f
Parser stuck fix
keyboardDrummer fd5fdf1
Fixes
keyboardDrummer 2defa7c
Fix test
keyboardDrummer 49e0900
Merge remote-tracking branch 'origin/main' into remy/pureProcedures
keyboardDrummer 2cd09af
Use function instead of pure procedure
keyboardDrummer ffa62ed
Fix docs
keyboardDrummer 65082fa
Add more checks to LaurelToCoreTranslator.lean
keyboardDrummer 82dd95c
Use a monad to make the code more readable
keyboardDrummer b1472a0
Update panic
keyboardDrummer 40a28ad
Fix
keyboardDrummer 2b39328
Merge branch 'main' into remy/pureProcedures
keyboardDrummer c9ed9fa
Add more test cases
keyboardDrummer 64a5ad8
Test updated and extra diagnostics
keyboardDrummer f02d1dc
Fix warnings
keyboardDrummer 4ad7c5e
Merge branch 'remy/pureProcedures' of github.com:strata-org/Strata in…
keyboardDrummer dbd4c1c
Merge remote-tracking branch 'origin/main' into remy/pureProcedures
keyboardDrummer 21dcb9b
Hit cache
keyboardDrummer 2c83631
Merge branch 'main' into remy/pureProcedures
keyboardDrummer eefc4cd
Merge branch 'main' into remy/pureProcedures
andrewmwells-amazon 33c2b9f
Merge remote-tracking branch 'origin/main' into remy/pureProcedures
keyboardDrummer 52ba56e
Updated comment
keyboardDrummer b2e5aa2
Introduce ids for identifiers
keyboardDrummer c8e091b
Some updates
keyboardDrummer b120036
Fixes
keyboardDrummer b739955
Updated ModifiesClauses
keyboardDrummer 70ec1ab
Updated a few transformations assuming we have a semanticModel
keyboardDrummer 5a7b39c
Changes
keyboardDrummer c35e08e
Merge branch 'remy/pureProcedures' into remy/LaurelResolution
keyboardDrummer d1046de
Updates
keyboardDrummer 1af2bea
Fixes
keyboardDrummer f397ac3
Fixed build errors
keyboardDrummer 3b63689
Fixes
keyboardDrummer 0bb0f82
Fix
keyboardDrummer cf163b4
Fixes
keyboardDrummer 3b2522d
Fixes
keyboardDrummer c18f69a
Bring back LaurelToCoreFromPureProcedures
keyboardDrummer 63af1e1
Merge remote-tracking branch 'origin/main' into remy/LaurelResolution
keyboardDrummer 7bc4988
Fixes
keyboardDrummer 59fd2e3
Fixes
keyboardDrummer edc0257
Fix
keyboardDrummer b1a0789
Fixes
keyboardDrummer 8406f2a
Updates
keyboardDrummer 09d81f6
Fixes
keyboardDrummer 484207a
Fixes
keyboardDrummer 813d251
Fixes
keyboardDrummer 9686c64
Fixes
keyboardDrummer da51850
Fix
keyboardDrummer be95aaf
Fix
keyboardDrummer ec38f8c
Fix
keyboardDrummer 72a3b61
Update to Resolution
keyboardDrummer dee810c
Fixes
keyboardDrummer 617eaf5
Fix
keyboardDrummer 7e05e23
Fixes
keyboardDrummer cef64f0
Fix
keyboardDrummer b33222c
No more panics
keyboardDrummer caa55da
Reduce debug output
keyboardDrummer e526cce
Fix
keyboardDrummer c844a82
Fixes
keyboardDrummer e8c1b37
Merge commit 'd4c952877~1' into remy/LaurelResolution
keyboardDrummer b377e1a
Merge commit 'd4c952877' into remy/LaurelResolution
keyboardDrummer 6ac4fa9
Merge remote-tracking branch 'origin/main' into remy/LaurelResolution
keyboardDrummer ac6113e
Replace calls to mkId with a coercion
keyboardDrummer 6e1a108
Fixes
keyboardDrummer d55e027
Rename Identifier.name to Identifier.text
keyboardDrummer 5df3e53
Fixes
keyboardDrummer c55ca5e
Fixes
keyboardDrummer b4025fa
Fix for PythonToLaurel
keyboardDrummer ad7ef4a
Python fixes
keyboardDrummer 7e4448b
Fixed and cleanup
keyboardDrummer 1253eb4
Cleanup
keyboardDrummer 0ee314b
Cleanup
keyboardDrummer 7c0e80c
Cleanup
keyboardDrummer dcc102b
Cleanup
keyboardDrummer 02efb77
Cleanup
keyboardDrummer c53af02
Simplify
keyboardDrummer 93a1c70
Cleanup
keyboardDrummer 4e363d0
Fixes
keyboardDrummer 1620ad5
Fixes
keyboardDrummer 2f582ec
Remove dbg output
keyboardDrummer 5979c60
Rename to avoid warning
keyboardDrummer 170fbdf
Updates
keyboardDrummer c7faf1d
Add hack
keyboardDrummer 4ff7855
Cleanup
keyboardDrummer 5dcbc5f
Add comment and remove useless derive
keyboardDrummer 7be6bd5
Remove DecidableEq for Identifier
keyboardDrummer 8a1efb9
Merge remote-tracking branch 'origin/main' into remy/LaurelResolution
keyboardDrummer a3c3060
Remove dbg_trace
keyboardDrummer e261beb
Remove softPanic
keyboardDrummer 24eddb7
Change handling of guillemets
keyboardDrummer 3240692
Remove partials, rename boogie => core, added comment to workaround, …
keyboardDrummer f82b5b0
Cleanup
keyboardDrummer b18c5ab
Remove two partials
keyboardDrummer a4e0275
Merge remote-tracking branch 'origin/main' into remy/LaurelResolution
keyboardDrummer 854bb0d
Merge branch 'main' into remy/LaurelResolution
joscoh File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| /- | ||
| Copyright Strata Contributors | ||
|
|
||
| SPDX-License-Identifier: Apache-2.0 OR MIT | ||
| -/ | ||
|
|
||
| import Strata.DDM.Elab | ||
| import Strata.DDM.AST | ||
| import Strata.Languages.Laurel.Grammar.LaurelGrammar | ||
| import Strata.Languages.Laurel.Grammar.ConcreteToAbstractTreeTranslator | ||
|
|
||
| namespace Strata.Laurel | ||
|
|
||
| /-- | ||
| Core map operations (`select`, `update`, `const`) expressed in Laurel syntax. | ||
| These are polymorphic map primitives used by the Laurel-to-Core translator. | ||
| Since Laurel doesn't have polymorphic types, `int` is used as a placeholder type | ||
| for all parameters — the actual types are inferred during Core translation. | ||
| -/ | ||
| def coreDefinitionsForLaurelDDM := | ||
| #strata | ||
| program Laurel; | ||
|
|
||
| // The types for these Map functions are incorrect. | ||
| // We'll fix them when Laurel supports polymorphism | ||
| function select(map: int, key: int) : int | ||
| external | ||
|
|
||
| function update(map: int, key: int, value: int) : int | ||
| external | ||
|
|
||
| function const(value: int) : int | ||
| external | ||
|
|
||
| #end | ||
|
|
||
| /-- | ||
| The core map operation definitions as a `Laurel.Program`, parsed at compile time. | ||
| -/ | ||
| def coreDefinitionsForLaurel : Program := | ||
| let uri := Strata.Uri.file "Strata/Languages/Laurel/CoreDefinitionsForLaurel.lean" | ||
| match TransM.run uri (parseProgram coreDefinitionsForLaurelDDM) with | ||
| | .ok program => program | ||
| | .error e => panic! s!"CoreDefinitionsForLaurel parse error: {e}" | ||
|
|
||
| end Strata.Laurel | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.