Bug 198838 - [WHLSL] Ensure MakeArrayReferenceExpression works
Summary: [WHLSL] Ensure MakeArrayReferenceExpression works
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGPU (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-06-13 12:04 PDT by Saam Barati
Modified: 2020-05-05 00:42 PDT (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Saam Barati 2019-06-13 12:04:56 PDT
There's some iffy looking code in metal codegen. E.g:

    if (is<AST::PointerType>(makeArrayReferenceExpression.resolvedType()))
        m_stringBuilder.append(makeString(mangledTypeName, ' ', variableName, " = { ", lValue, ", 1 };\n"));


I think it should instead be something like " = lvalue"
Comment 1 Saam Barati 2019-06-13 12:06:06 PDT
I'm gonna fly by change it in a patch I'm writing for OOB accesses, but it needs to be tested and thought through in a more thorough way.
Comment 2 Saam Barati 2019-06-13 12:09:39 PDT
(In reply to Saam Barati from comment #1)
> I'm gonna fly by change it in a patch I'm writing for OOB accesses, but it
> needs to be tested and thought through in a more thorough way.

I'm not doing this. The bug is the code is checking the result type. It should be checking the base type.
Comment 3 Myles C. Maxfield 2020-05-05 00:42:29 PDT
WHLSL is no longer relevant.