Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

DEPS in impeller and build unit tests#31227

Merged
zanderso merged 1 commit intoflutter:mainfrom
zanderso:deps-impeller
Feb 5, 2022
Merged

DEPS in impeller and build unit tests#31227
zanderso merged 1 commit intoflutter:mainfrom
zanderso:deps-impeller

Conversation

@zanderso
Copy link
Member

@zanderso zanderso commented Feb 3, 2022

To get the impeller unit tests building, I had to make these changes along with flutter/buildroot#545 in the buildroot.

Impeller expects flutter::Dispatcher::transformReset() to exist so I added it to the interface, and empty implementations where needed to build, but I don't know if they need real implementations.

@chinmaygarde @bdero @flar

@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat.

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.

@zanderso zanderso force-pushed the deps-impeller branch 2 times, most recently from 2567df7 to c34f991 Compare February 3, 2022 20:41
@zanderso
Copy link
Member Author

zanderso commented Feb 3, 2022

Expected to fail outside of Mac. But failing on Mac with:

FAILED: shaders/shader_fixtures.metallib 
python3 ../../flutter/impeller/tools/build_metal_library.py --output shaders/shader_fixtures.metallib --depfile /opt/s/w/ir/cache/builder/src/out/host_debug_unopt/gen/flutter/impeller/fixtures/shader_deps/shader_fixtures.depfile --platform=mac --source gen/flutter/impeller/fixtures/box_fade.vert.metal --source gen/flutter/impeller/fixtures/box_fade.frag.metal --source gen/flutter/impeller/fixtures/test_texture.vert.metal --source gen/flutter/impeller/fixtures/test_texture.frag.metal
metal: error: unknown argument: '-frecord-sources'

@zanderso
Copy link
Member Author

zanderso commented Feb 4, 2022

Maybe this is an xcode version issue? @jmagman can you remind me which version of XCode is on Engine CI. I also remember there were discussions about upgrading. Do you know which version the upgrade is targeting?

@zanderso
Copy link
Member Author

zanderso commented Feb 4, 2022

https://developer.apple.com/documentation/metal/libraries/generating_and_loading_a_metal_library_symbol_file seems to be saying that -frecord-sources is Xcode 13 and later.

@jmagman
Copy link
Member

jmagman commented Feb 4, 2022

https://developer.apple.com/documentation/metal/libraries/generating_and_loading_a_metal_library_symbol_file seems to be saying that -frecord-sources is Xcode 13 and later.

Ugh that's unfortunate, the engine builders are on Xcode 12.3. @yusuf-goog is working on getting the engine builders macOS version updated to unblock the migration to Xcode 13 https://docs.google.com/document/d/1M9HqJeEAisqgClRfxdXYBhYWJdiu2A-zSOovCBO7yjg/edit# (internal link)

@chinmaygarde
Copy link
Contributor

We don't need Xcode 13 for Impeller. The -frecord-sources is the much more readable version of the older -M0 flag that puts sources and driver options in the compiled shader output so that profile mode builds enable shader debugging and profiling.

I used the newer flag after reading about it in the man page when I was re-reading my own code and could not figure out what M0 meant. I'll back it out.

@zanderso zanderso force-pushed the deps-impeller branch 2 times, most recently from 64f4a68 to 2db89cb Compare February 4, 2022 21:58
@zanderso
Copy link
Member Author

zanderso commented Feb 4, 2022

Adjusted license checker for stb and filed flutter/flutter#97843 for its removal.

@zanderso zanderso force-pushed the deps-impeller branch 3 times, most recently from 6fd0d33 to a103284 Compare February 4, 2022 23:57
Copy link
Contributor

@bdero bdero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm 👍 I wiped away my setup and successfully ran impeller_unittests against this branch.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants