mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 18:07:34 +00:00
DevTools: Remove redundant default destructor and forward declarations
Problem: - Default destructors (and constructors) are in `.cpp` files. This prevents the compiler's optimizer from inlining them when it thinks inlining is appropriate (unless LTO is used). - Forward declarations can prevent some optimizations, such as inlining of constructors and destructors. Solution: - Remove them or set them to `= default` and let the compiler handle the generation of them. - Remove unneeded forward declarations.
This commit is contained in:
parent
4d34802f74
commit
6ac454e70a
9 changed files with 43 additions and 53 deletions
|
@ -47,10 +47,6 @@ Profile::Profile(Vector<Process> processes, Vector<Event> events)
|
|||
rebuild_tree();
|
||||
}
|
||||
|
||||
Profile::~Profile()
|
||||
{
|
||||
}
|
||||
|
||||
GUI::Model& Profile::model()
|
||||
{
|
||||
return *m_model;
|
||||
|
|
|
@ -6,7 +6,11 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "DisassemblyModel.h"
|
||||
#include "Process.h"
|
||||
#include "Profile.h"
|
||||
#include "ProfileModel.h"
|
||||
#include "SamplesModel.h"
|
||||
#include <AK/Bitmap.h>
|
||||
#include <AK/FlyString.h>
|
||||
#include <AK/JsonArray.h>
|
||||
|
@ -22,11 +26,6 @@
|
|||
|
||||
namespace Profiler {
|
||||
|
||||
class DisassemblyModel;
|
||||
class Profile;
|
||||
class ProfileModel;
|
||||
class SamplesModel;
|
||||
|
||||
class ProfileNode : public RefCounted<ProfileNode> {
|
||||
public:
|
||||
static NonnullRefPtr<ProfileNode> create(FlyString object_name, String symbol, u32 address, u32 offset, u64 timestamp, pid_t pid)
|
||||
|
@ -130,7 +129,6 @@ struct ProcessFilter {
|
|||
class Profile {
|
||||
public:
|
||||
static Result<NonnullOwnPtr<Profile>, String> load_from_perfcore_file(const StringView& path);
|
||||
~Profile();
|
||||
|
||||
GUI::Model& model();
|
||||
GUI::Model& samples_model();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue