RESOLVED FIXED 199460
[WHLSL] Make the destructor of VariableDeclaration non-virtual
https://bugs.webkit.org/show_bug.cgi?id=199460
Summary [WHLSL] Make the destructor of VariableDeclaration non-virtual
Robin Morisset
Reported 2019-07-03 13:16:49 PDT
Three steps: - Remove WHLSL::AST::Value, inlining it into its children (it is trivial, it just has one field m_origin with a getter and nothing else) - Mark WHLSL::AST::VariableDeclaration final - Now that it inherits from nothing and nothing can inherit from it, there is no reason for it to have any virtual method, including its destructor. This not only saves 8 bytes from every variable declaration (for the virtual table pointer), it also should make destructing the AST at the end of compilation a bit faster by removing the virtual destructor call.
Attachments
Patch (11.19 KB, patch)
2019-07-03 17:15 PDT, Robin Morisset
no flags
Robin Morisset
Comment 1 2019-07-03 17:15:48 PDT
WebKit Commit Bot
Comment 2 2019-07-03 18:06:41 PDT
Comment on attachment 373441 [details] Patch Clearing flags on attachment: 373441 Committed r247124: <https://trac.webkit.org/changeset/247124>
WebKit Commit Bot
Comment 3 2019-07-03 18:06:42 PDT
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 4 2019-07-03 18:07:16 PDT
Note You need to log in before you can comment on or make changes to this bug.