Skip to content

Pass schema object as pointer to symcc targets#747

Merged
john-h-kastner-aws merged 3 commits into
mainfrom
lean_schema_cache
Sep 26, 2025
Merged

Pass schema object as pointer to symcc targets#747
john-h-kastner-aws merged 3 commits into
mainfrom
lean_schema_cache

Conversation

@john-h-kastner-aws

@john-h-kastner-aws john-h-kastner-aws commented Sep 26, 2025

Copy link
Copy Markdown
Contributor

Adds and exports a new Lean function loadProtobufSchema which parses a schema from protobuf and returns a lean object for that schema. This object is then passed to all the symcc lean ffi function.

This avoid re-parsing the schema for every request environment.

Fixes #741. For the one slow unit I tested this on, run time is reduced from 6928ms to 562ms. Currently running effected fuzz targets locally and I haven't found any issues

This avoid re-parsing the schema for every request environement.

Signed-off-by: John Kastner <jkastner@amazon.com>
Signed-off-by: John Kastner <jkastner@amazon.com>
@john-h-kastner-aws

Copy link
Copy Markdown
Contributor Author

Currently have 3 hours running each of the fuzz impacted fuzz targets, so I'm pretty confident this won't break anything in the weekend test runs

@john-h-kastner-aws john-h-kastner-aws merged commit 494b3db into main Sep 26, 2025
13 checks passed
@john-h-kastner-aws john-h-kastner-aws deleted the lean_schema_cache branch September 29, 2025 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Optimize lean FFI for symcc

3 participants