Skip to content

Conversation

@acoates-ms
Copy link
Contributor

@acoates-ms acoates-ms commented Apr 17, 2020

Fixes #4122

There seems to be an issue with the v142 compiler bits which causes the code generated around CompactValue.isUndefined to not always return the correct value.

Using fp:Strict within yoga.cpp works around the issue.
An alternative would be to fork CompactValue, and add pragma's to enable strict just around that. -- Or wait for a compiler fix. We should look at disabling this change on compiler updates to see if the compiler issue has been fixed.

Microsoft Reviewers: Open in CodeFlow

@acoates-ms acoates-ms requested a review from a team as a code owner April 17, 2020 18:05
<ClCompile Include="$(YogaDir)\yoga\YGStyle.cpp" DisableSpecificWarnings="4244;%(DisableSpecificWarnings)" />
<ClCompile Include="$(YogaDir)\yoga\YGValue.cpp" />
<ClCompile Include="$(YogaDir)\yoga\Yoga.cpp" DisableSpecificWarnings="4244;%(DisableSpecificWarnings)" />
<ClCompile Condition="'$(Platform)' == 'x64'" Include="$(YogaDir)\yoga\Yoga.cpp" DisableSpecificWarnings="4244;%(DisableSpecificWarnings)" FloatingPointModel="Strict" />
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you add a comment with a link to the issue here?

Copy link
Member

Choose a reason for hiding this comment

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

Note that I'm only able to see a difference in we build x64 AND Release (x64 Debug looks ok)
image

@asklar
Copy link
Member

asklar commented Apr 17, 2020

Could you file an issue to undo this workaround when we get a fix from MSVC?

<ClCompile Include="$(YogaDir)\yoga\YGStyle.cpp" DisableSpecificWarnings="4244;%(DisableSpecificWarnings)" />
<ClCompile Include="$(YogaDir)\yoga\YGValue.cpp" />
<ClCompile Include="$(YogaDir)\yoga\Yoga.cpp" DisableSpecificWarnings="4244;%(DisableSpecificWarnings)" />
<ClCompile Condition="'$(Platform)' == 'x64'" Include="$(YogaDir)\yoga\Yoga.cpp" DisableSpecificWarnings="4244;%(DisableSpecificWarnings)" FloatingPointModel="Strict" />
Copy link
Member

Choose a reason for hiding this comment

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

Note that I'm only able to see a difference in we build x64 AND Release (x64 Debug looks ok)
image

@acoates-ms
Copy link
Contributor Author

Yes, but we may as well have debug match the strict mode to try to minimize the differences between release and debug.

@acoates-ms acoates-ms added the AutoMerge Causes a PR to be automatically merged once all requirements are passed (label drives bot activity) label Apr 17, 2020
@ghost
Copy link

ghost commented Apr 17, 2020

Hello @acoates-ms!

Because this pull request has the AutoMerge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@ghost ghost merged commit a67124c into microsoft:master Apr 17, 2020
asklar pushed a commit to asklar/react-native-windows that referenced this pull request Apr 19, 2020
* Fix issue with yoga layout in x64 release

* Change files

* Update E2E masters

* code review feedback
@acoates-ms acoates-ms deleted the x64releaseyoga branch May 21, 2020 17:16
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AutoMerge Causes a PR to be automatically merged once all requirements are passed (label drives bot activity)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

E2ETest failure: Padding doesn't work for Views on VS 2019, v142 tools, Release x64

3 participants