[foreign-jextract] Integrated: 8260583: jextract generates redundant constant files

Maurizio Cimadamore mcimadamore at openjdk.java.net
Thu Jan 28 12:32:09 UTC 2021


On Thu, 28 Jan 2021 12:10:21 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

> When testing performances of jextract generated code with big headers, I noticed that jextract was emitting empty constant files. After some debugging, I realized that the issues lies in the fact that `ConstantHelper::build` is called both by `ToplevelBuilder::build` and by `HeaderFileBuilder::build` - so, for every new header file split that is generated, we trigger a new constant file, even though that is not needed.
> 
> The solution is to remove the call from `HeaderFileBuilder` and just keep the one inside `TopLevelBuilder`.

This pull request has now been integrated.

Changeset: 1233eafd
Author:    Maurizio Cimadamore <mcimadamore at openjdk.org>
URL:       https://git.openjdk.java.net/panama-foreign/commit/1233eafd
Stats:     78 lines in 3 files changed: 75 ins; 2 del; 1 mod

8260583: jextract generates redundant constant files

Reviewed-by: sundar

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

PR: https://git.openjdk.java.net/panama-foreign/pull/440


More information about the panama-dev mailing list