This is an archive of the discontinued LLVM Phabricator instance.

[ExecutionEngine] Fix a compiler warning in StoreValueToMemory
AbandonedPublic

Authored by labath on Apr 24 2019, 6:04 AM.

Details

Reviewers
lhames
Summary

gcc was diagnosing a memcpy in this function with "memcpy writing to an
object of type 'struct llvm::GenericValue' with no trivial
copy-assignment". After closer examination, it became clear that the
pointer in the function *never* refers to a GenericValue object, and all
callers cast some other pointer (typically void*) to GenericValue*.
There doesn't seem to be any reason for such a convoluted solution so I
just change the function to accept a void* instead, which has the nice
side-effect of fixing the warning as well.

Diff Detail

Event Timeline

labath created this revision.Apr 24 2019, 6:04 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 24 2019, 6:04 AM
labath abandoned this revision.Jul 26 2019, 6:16 AM

not relevant anymore