requiring is_component_build = false for dawn.node ok?

26 views
Skip to first unread message

Gregg Tavares

unread,
Sep 10, 2026, 9:43:28 PMSep 10
to Dawn Graphics
TL;DR: Is it going to affect anyone to require is_component_build = false for dawn.node ?

Long version: I found out recently that, at least on Linux, building dawn node with component build ends up with an Abseil conflict between the one in dawn and the one in node 

I just added a README note about it but Kai suggested adding a BUILD.gn assert

I think though, for dawn devs using dawn.node, they don't hit the conflict. Testing linux with component build true, dawn.node works for `webgpu:shader,*`

It's only a specific test in src/dawn/node/test.mjs that segfautls when in component build which was traced to this Abseil conflict and switching to the non-component build fixed it.

So, okay to add the build assert? Or just leave it as a README note?





David Neto

unread,
Sep 11, 2026, 10:14:59 AMSep 11
to Gregg Tavares, Dawn Graphics
I think the assert is fine.

Context: I always use ./tools/setup-build to create my GN build environment, and that never mentions is_component_build.

david



--
You received this message because you are subscribed to the Google Groups "Dawn Graphics" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dawn-graphic...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dawn-graphics/CAKZ%2BBNpE934te9U0sWXbDtBe3TPrP5coYQuhhW4BvKyMwCenjg%40mail.gmail.com.

Antonio Maiorano

unread,
Sep 11, 2026, 10:15:14 AMSep 11
to Gregg Tavares, Dawn Graphics
It would be nice not to be forced to use `is_component_build = false` when building dawn.node. I searched for this problem, since we can't be the first to run into it specifically with Abseil, and found out that Abseil seems to have a solution for this problem via the ABSL_OPTION_USE_INLINE_NAMESPACE macro. See here and here. Basically we can provide a unique inline namespace for the copy of Abseil used by Dawn so that the mangled names are unique and don't collide. Having said that, I'm struggling to find examples of this being used in other projects. Might be worth a try.


On Thu, Sep 10, 2026 at 9:43 PM 'Gregg Tavares' via Dawn Graphics <dawn-g...@googlegroups.com> wrote:
--
You received this message because you are subscribed to the Google Groups "Dawn Graphics" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dawn-graphic...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/dawn-graphics/CAKZ%2BBNpE934te9U0sWXbDtBe3TPrP5coYQuhhW4BvKyMwCenjg%40mail.gmail.com.


--
Antonio Maiorano

Kai Ninomiya

unread,
Sep 11, 2026, 6:49:04 PMSep 11
to Antonio Maiorano, Gregg Tavares, Dawn Graphics
Nice find, that definitely sounds preferable, and I think it might even avoid issues with linking Dawn into other projects?

I don't think it's a huge problem if dawn.node requires non-component builds, but it will be annoying to team members especially using dawn_maximal=true.
(Component builds only matter to Dawn developers, as the only point is to speed up incremental compilation. And I'm not even sure how much speedup there is in Dawn since it's not that huge of a project.)

-Kai (he/they)


Kai Ninomiya

unread,
Sep 15, 2026, 6:17:18 PM (13 days ago) Sep 15
to Antonio Maiorano, Gregg Tavares, Dawn Graphics
FWIW I measured the local speedup on an offline incremental build (after touching only DeviceMTL.mm) and got roughly:
- component build (default): all targets 23s, dawn_end2end_tests 10s
- non-component build: all targets 60s, dawn_end2end_tests 11s

So pretty useful. Also it is the default.

-Kai (he/they)

Reply all
Reply to author
Forward
0 new messages