clean-ide merge requestshttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests2019-05-10T16:30:12+02:00https://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/16Abc interpreter improvements2019-05-10T16:30:12+02:00Camil StapsAbc interpreter improvementsThis MR makes two important improvements to the workflow for generating optimised ABC and bytecode:
1. It adds new stages for these steps, so that the timestamps of these files differ for large projects preventing unnecessary regenerati...This MR makes two important improvements to the workflow for generating optimised ABC and bytecode:
1. It adds new stages for these steps, so that the timestamps of these files differ for large projects preventing unnecessary regeneration. (Previously, both optimizing and generating bytecode were done per module in `GenCodeTheProjectModule`).
2. If a bytecode file exists, we now check whether the bytecode generator installed has a different instruction set version number, and regenerates the file if this is the case. This prevents parsing errors in the bytecode linker. (Previously, you would have to manually trigger regeneration by deleting the bytecode files or touching source files.) The instruction set version number may change when new instructions are added or if the format changes.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/15Resolve "cpm environment options"2019-04-12T13:28:44+02:00Mart LubbersResolve "cpm environment options"Closes #2
- [x] ListEnvironments
- [x] ImportEnvironment FilePath
- [x] RemoveEnvironment String
- [x] ShowEnvironment String
- [x] ExportEnvironment String
- [x] CreateEnvironment String
- [x] RenameEnvironment String String
...Closes #2
- [x] ListEnvironments
- [x] ImportEnvironment FilePath
- [x] RemoveEnvironment String
- [x] ShowEnvironment String
- [x] ExportEnvironment String
- [x] CreateEnvironment String
- [x] RenameEnvironment String String
- [x] SetEnvironmentCompiler String String
- [x] SetEnvironmentCodeGen String String
- [x] EnvironmentHelpJohn van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/14Search hierarchically for imported object files2019-04-11T15:02:50+02:00Mart LubbersSearch hierarchically for imported object filesPreviously an imported object file:
```
implementation module test.test
import code from "obj.o"
```
Would only search in the roots of the project paths. Now it will als
search in the test/ folder in the root.
This is achieved by reme...Previously an imported object file:
```
implementation module test.test
import code from "obj.o"
```
Would only search in the roots of the project paths. Now it will als
search in the test/ folder in the root.
This is achieved by remembering in which module the import was done and using this to search hierarchically for the object file. It is backwards compatible, it will only search hierarchically if it failed to find the object file the old fashioned way.
Things I need to do before merging:
- [x] Test on windowsJohn van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/13Add EnvironmentByteCodePrelink and PrelinkByteCode options to prelink bytecode2019-04-09T22:30:57+02:00Camil StapsAdd EnvironmentByteCodePrelink and PrelinkByteCode options to prelink bytecodeDepends on https://gitlab.science.ru.nl/clean-and-itasks/clean-build/merge_requests/47.Depends on https://gitlab.science.ru.nl/clean-and-itasks/clean-build/merge_requests/47.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/12Add option KeepByteCodeSymbols to keep the symbol table when stripping bytecode2019-04-08T13:12:37+02:00Camil StapsAdd option KeepByteCodeSymbols to keep the symbol table when stripping bytecodeOption `-s` of `bcstrip` was added in https://gitlab.science.ru.nl/clean-and-itasks/abc-interpreter/commit/49085f9cba5c283a8680e8b4065b6ae4e4e410ec.
So there are basically three options:
1. Strip sections and symbol table (useful w...Option `-s` of `bcstrip` was added in https://gitlab.science.ru.nl/clean-and-itasks/abc-interpreter/commit/49085f9cba5c283a8680e8b4065b6ae4e4e410ec.
So there are basically three options:
1. Strip sections and symbol table (useful when you just want to interpret)
2. Strip sections but keep symbols (useful when you want to serialize/deserialize)
3. Don't strip (useful if you suspect a bug in the stripper)
Before you would need option 3 for using the serialization library, but now the most sensible default is option 2.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/11Only generate new optimised ABC and bytecode when the source file is newer2019-04-08T13:10:43+02:00Camil StapsOnly generate new optimised ABC and bytecode when the source file is newerThis checks whether the source files for optimised ABC / bytecode are younger, and only regenerates the targets when needed.
The bytecode linker and stripper are still called every time.This checks whether the source files for optimised ABC / bytecode are younger, and only regenerates the targets when needed.
The bytecode linker and stripper are still called every time.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/10Move project options related to bytecode generation to new separate pane2019-02-06T15:04:10+01:00Camil StapsMove project options related to bytecode generation to new separate paneThis moves the options related to bytecode generation (added in !9) to a new separate pane. This should also clarify that "Use optimised ABC" is only relevant when generating bytecode. I have also added the checkbox to toggle bytecode st...This moves the options related to bytecode generation (added in !9) to a new separate pane. This should also clarify that "Use optimised ABC" is only relevant when generating bytecode. I have also added the checkbox to toggle bytecode stripping now.
The new interface looks like this:
![2019-02-06-143701_429x532](/uploads/7d099fbe41b48457db47b8e037bb4eb6/2019-02-06-143701_429x532.png)John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/9Add support for bytecode generation to cpm and IDE2019-02-06T14:40:14+01:00Camil StapsAdd support for bytecode generation to cpm and IDEThis adds support for generating binary and optimised ABC code to `cpm` and the IDE.
In target environments, four new options are added:
- `EnvironmentABCOptimise`, path to the ABC optimiser (generates `<module>.opt.abc` from `<mod...This adds support for generating binary and optimised ABC code to `cpm` and the IDE.
In target environments, four new options are added:
- `EnvironmentABCOptimise`, path to the ABC optimiser (generates `<module>.opt.abc` from `<module>.abc`)
- `EnvironmentByteCodeGen`, path to the bytecode generator (generates `<module>.bc` from `<module>[.opt].abc`)
- `EnvironmentByteCodeLink`, path to the bytecode linker (generates one `<application>.bc` from all bytecode files)
- `EnvironmentByteCodeStrip`, path to the bytecode stripper (strips an `<application>.bc`, overwriting that file)
In project files, four new options are added:
- `ByteCode`, path to the main bytecode file to generate (result of the bytecode linker)
- `CodeGen/OptimiseABC`, boolean indicating whether to generate optimised ABC code
- `CodeGen/GenerateByteCode`, boolean indicating whether to generate bytecode
- `Link/StripByteCode`, boolean indicating whether the bytecode stripper should be used
Notes:
- The default behaviour is unchanged: no bytecode is generated when these options are absent.
- When `ByteCode` is non-empty but `CodeGen/GenerateByteCode` is false, some files may be missing which can lead to errors in the linking step.
- If `CodeGen/GenerateByteCode` is true but `CodeGen/OptimiseABC` is false, we generate bytecode from the unoptimised ABC files. This has no real use case for now.
- `Link/StripByteCode` should be false to use the serialization library, but can be true if you just want to run the interpreter stand-alone for example).
- In the IDE one can set all project options except `Link/StripBytecode`, which has no real use case for now.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/8cpm: Various minor fixes2019-01-15T11:46:38+01:00Mart Lubberscpm: Various minor fixes- Fix showing help for path actions
- Add missing help for `-h` and `-s`
- Add help for compiling a single module
- Allows multiple modules to be compiled at once- Fix showing help for path actions
- Add missing help for `-h` and `-s`
- Add help for compiling a single module
- Allows multiple modules to be compiled at onceJohn van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/7Fix double flags mac2019-01-14T14:40:54+01:00John van GroningenFix double flags machttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/6Enables only using GCC on linux2019-01-14T11:54:47+01:00Mart LubbersEnables only using GCC on linuxThis adds the option, similar as to mac has this, to directly use gcc without using the optimizing linker.
This is necessary to keep the linker from stripping the debug symbols needed for platform independent graph (de)serialization.This adds the option, similar as to mac has this, to directly use gcc without using the optimizing linker.
This is necessary to keep the linker from stripping the debug symbols needed for platform independent graph (de)serialization.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/5Support options2 for linker as well2019-01-10T13:53:18+01:00Mart LubbersSupport options2 for linker as wellThe following entry in IDEEnvs:
```
EnvironmentLinker: lib/exe/linker:-h 200m:-lmysql
```
Will call the linker with a heap of 200M and pass -lmysql to gcc/ld
In some extravagant cases (large projects with descriptors etc.), th...The following entry in IDEEnvs:
```
EnvironmentLinker: lib/exe/linker:-h 200m:-lmysql
```
Will call the linker with a heap of 200M and pass -lmysql to gcc/ld
In some extravagant cases (large projects with descriptors etc.), the linker needs more heap as well.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/4cpm: Support adding multiple paths2019-01-10T13:41:59+01:00Mart Lubberscpm: Support adding multiple pathsJohn van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/3Update project files for linux and add CI2019-01-10T13:25:20+01:00Mart LubbersUpdate project files for linux and add CIThe CI automatically builds `cpm`.
Note that this is not a substitute for the buildserver, it _just_ builds it and if it fails it will state so.
It's just an extra check that there are no errors.The CI automatically builds `cpm`.
Note that this is not a substitute for the buildserver, it _just_ builds it and if it fails it will state so.
It's just an extra check that there are no errors.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/2Add newlines to errors2019-01-10T13:13:40+01:00Mart LubbersAdd newlines to errorsOn mac and linux an abort without a newline results in a somewhat mangled shell.On mac and linux an abort without a newline results in a somewhat mangled shell.John van GroningenJohn van Groningenhttps://gitlab.science.ru.nl/clean-and-itasks/clean-ide/-/merge_requests/1Add profiling and rts options to cpm2019-01-10T13:09:19+01:00Mart LubbersAdd profiling and rts options to cpmThis adds options for:
- RTS command line flags (-rtsopts and -nrtsopts in clm)
- Stack profiling (-tst, -ntst)
- Time profiling (-pt, -npt)
- Memory profiling (-mp, -nmp)
It also fixes a typo in the descexl optionThis adds options for:
- RTS command line flags (-rtsopts and -nrtsopts in clm)
- Stack profiling (-tst, -ntst)
- Time profiling (-pt, -npt)
- Memory profiling (-mp, -nmp)
It also fixes a typo in the descexl optionJohn van GroningenJohn van Groningen