Closed Bug 893221 Opened 7 years ago Closed 7 years ago

Crash using OMTC and Windows 7

Categories

(Core :: Graphics, defect)

Other Branch
x86
Windows 7
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla25

People

(Reporter: dvander, Assigned: dvander)

References

Details

(Keywords: crash, Whiteboard: [e10s])

Attachments

(1 file)

On the electrolysis branch, I'm getting a startup crash because LayerManagerComposite::Initialize() is returning false. In gfxWindowsPlatform.cpp, we request D3D_FEATURE_LEVEL_11_1 from d3d11CreateDevice(). According to MSDN, requesting this feature if DirectX 11.1 is not present will automatically return E_INVALIDARG, and DirectX 11.1 is Windows 8 only.

Would it be okay to just re-request a device with a fallback feature list, or should we check the Windows version before requesting 11.1?
Keywords: crash
Version: unspecified → Other Branch
Blocks: 756606
Widget exports WinUtils for easy version checking, FWIW - 

http://mxr.mozilla.org/mozilla-central/source/widget/windows/WinUtils.h#43
Attached patch fixSplinter Review
Thanks - It turned out there was something similar right in the file so I just used that.
Assignee: nobody → dvander
Status: NEW → ASSIGNED
Attachment #777443 - Flags: review?
Attachment #777443 - Flags: review? → review?(bas)
Attachment #777443 - Flags: review?(bas) → review+
Comment on attachment 777443 [details] [diff] [review]
fix

Review of attachment 777443 [details] [diff] [review]:
-----------------------------------------------------------------

::: gfx/thebes/gfxWindowsPlatform.cpp
@@ +1464,5 @@
>    }
>  
> +  nsTArray<D3D_FEATURE_LEVEL> featureLevels;
> +  if (gfxWindowsPlatform::WindowsOSVersion() >= gfxWindowsPlatform::kWindows8)
> +    featureLevels.AppendElement(D3D_FEATURE_LEVEL_11_1);

Will this enum value be declared on Win <8? Or will we get a compile error for undeclared identifier?

Nit: {} please
You might consider ditching gfxWindowsPlatform::WindowsOSVersion all together and use WinUtils::WindownVersion() -

http://mxr.mozilla.org/mozilla-central/source/widget/windows/WinUtils.h#43
https://hg.mozilla.org/mozilla-central/rev/11d4b5839cd5
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla25
You need to log in before you can comment on or make changes to this bug.