This is an archive of the discontinued LLVM Phabricator instance.

[VLIWMachineScheduler] Disable default copy ctor and copy assignment operator for VLIWSchedBoundary
ClosedPublic

Authored by yubing on May 30 2023, 2:26 AM.

Details

Summary

class VLIWSchedBoundary manages resources such as dynamically allocated memory, it's generally a good practice to either implement a custom copy constructor or disable the default one.

Diff Detail

Event Timeline

yubing created this revision.May 30 2023, 2:26 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 30 2023, 2:26 AM
yubing requested review of this revision.May 30 2023, 2:26 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 30 2023, 2:26 AM
JamesNagurne added inline comments.May 30 2023, 10:23 AM
llvm/include/llvm/CodeGen/VLIWMachineScheduler.h
155

What is the reasoning here? It's not obvious to me.

yubing edited the summary of this revision. (Show Details)May 30 2023, 7:32 PM
yubing added inline comments.
llvm/include/llvm/CodeGen/VLIWMachineScheduler.h
155

class VLIWSchedBoundary manages resources such as dynamically allocated memory, it's generally a good practice to either implement a custom copy constructor or disable the default one.

JamesNagurne accepted this revision.May 30 2023, 10:22 PM
JamesNagurne added inline comments.
llvm/include/llvm/CodeGen/VLIWMachineScheduler.h
155

Understood! Was just curious if there was any other motive. LGTM

This revision is now accepted and ready to land.May 30 2023, 10:22 PM