dd49617f92
Explanation: The sksl standalone compiler is used to convert the raw (text) SkSL pre-includes into a "dehydrated" binary format. It also (previously) depended on those files, as they were #included and used, unless a special #define was changed. This created a dependency cycle that we hid from GN (by lying about the outputs of the dehydrate step). As a result, builds would never reach steady-state, because the compiler would be rebuilt (due to the newer dehydrated files), and then the dehydrated files would be rebuilt (due to the newer compiler). This CL changes the logic so that the standalone compiler always uses the textual pre-includes, and no longer depends on the dehydrated binary files. Thus, to make any kind of change to the dehydrated files (whether due to pre-include changes, or the encoding format itself), you just need skia_compile_processors enabled. The dependencies are now honestly communicated to GN, and we reach steady state after one build. The NOTE above is because GN/ninja cache the dependencies of each target, and will still think that the SkSLCompiler.obj linked into the standalone compiler depends on the dehydrated files, at least until one successful build, when it will realize that's no longer true. Reland notes: The bots originally rejected this CL, because SkSLCompiler was hard-coded to load the text files from a relative path that assumed the executable was in "<skia_checkout>/out/<some_dir>". That's not true for bots, and it was fragile, even for users. Now, we use GN to directly generate sksl_fp.sksl, and copy all of the other pre-includes to the root out dir (working directory when running skslc). This means we no longer need to generate the sksl_fp.sksl file into the src tree, and the compiler can more safely assume that the files will be in the working directory. Bug: skia:10571 Change-Id: Id7837a9aba7ee0c3f7fa82eb84f7761e24b9c705 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/308896 Reviewed-by: Mike Klein <mtklein@google.com> Reviewed-by: John Stiles <johnstiles@google.com> Reviewed-by: Michael Ludwig <michaelludwig@google.com> Commit-Queue: Brian Osman <brianosman@google.com> |
||
---|---|---|
.. | ||
toolchain | ||
__init__.py | ||
bench.gni | ||
BUILD.gn | ||
BUILDCONFIG.gn | ||
call.py | ||
checkdir.py | ||
checkpath.py | ||
codesign_ios.py | ||
compile_ib_files.py | ||
compile_processors.py | ||
copy_git_directory.py | ||
core.gni | ||
cp.py | ||
create_sksl_fp.py | ||
dehydrate_sksl.py | ||
effects_imagefilters.gni | ||
effects.gni | ||
find_headers.py | ||
find_msvc.py | ||
find_xcode_sysroot.py | ||
flutter_defines.gni | ||
fuchsia_defines.gni | ||
gen_plist_ios.py | ||
gm.gni | ||
gn_meta_sln.py | ||
gn_to_bp_utils.py | ||
gn_to_bp.py | ||
gn_to_cmake.py | ||
gpu.gni | ||
highest_version_dir.py | ||
ios.gni | ||
is_clang.py | ||
make_gm_gni.py | ||
opts.gni | ||
pdf.gni | ||
push_to_android.py | ||
rm.py | ||
run_sksllex.py | ||
samples.gni | ||
shared_sources.gni | ||
skia.gni | ||
sksl.gni | ||
tests.gni | ||
utils.gni | ||
xps.gni |