[code-reflection] RFR: Model verifier [v2]

Adam Sotona asotona at openjdk.org
Fri Oct 11 07:36:52 UTC 2024


> This patch starts work on model `Verifier` and implements following verifications:
>  - operands declaration dominance
>  - `BranchOp` reference arguments matching target block parameters (simple matching by `TypeKind` with erased `int` sub-types)
>  - `ArithmeticOperation`, `TestOperation` and `ConvOp` verified presence of relevant method handler in `InvokableLeafOps`
>  
> `TestSmallCorpus` is improved to verify code model.
> 
> Fixes of bugs newly discovered by the `TestSmallCorpus`:
>  - missing methods in `InvokableLeafOps`
>  - `Interpreter` use of provided lookup for `resolveToMethodType`
>  - `Interpreter` erase  sub-`int` types for `InvokeOp` execution + added `TestLiftCustomBytecode::testEraseInts`
> -  Removed complex sub-`int` types calculation from `BytecodeLift` and `LocalsToVarMapper` 
> - `BytecodeLift` fixed to avoid production of some obsolete block parameters

Adam Sotona has updated the pull request incrementally with one additional commit since the last revision:

  Verifier.VerifyError not extending Error

-------------

Changes:
  - all: https://git.openjdk.org/babylon/pull/247/files
  - new: https://git.openjdk.org/babylon/pull/247/files/104ef7dd..2155ccb3

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=babylon&pr=247&range=01
 - incr: https://webrevs.openjdk.org/?repo=babylon&pr=247&range=00-01

  Stats: 14 lines in 2 files changed: 10 ins; 0 del; 4 mod
  Patch: https://git.openjdk.org/babylon/pull/247.diff
  Fetch: git fetch https://git.openjdk.org/babylon.git pull/247/head:pull/247

PR: https://git.openjdk.org/babylon/pull/247


More information about the babylon-dev mailing list