Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Prog2
/
labor_peldak
/
lab_11
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
49821d94
authored
May 25, 2023
by
Zoltan Karsa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update memtrace
parent
e733606f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
5 deletions
+28
-5
diamond/memtrace.cpp
+9
-1
diamond/memtrace.h
+19
-4
No files found.
diamond/memtrace.cpp
View file @
49821d94
...
@@ -488,6 +488,13 @@ void operator delete[](void * p) THROW_NOTHING {
...
@@ -488,6 +488,13 @@ void operator delete[](void * p) THROW_NOTHING {
memtrace
::
traced_delete
(
p
,
FDELETEARR
);
memtrace
::
traced_delete
(
p
,
FDELETEARR
);
}
}
void
operator
delete
(
void
*
p
,
size_t
)
THROW_NOTHING
{
memtrace
::
traced_delete
(
p
,
FDELETE
);
}
void
operator
delete
[](
void
*
p
,
size_t
)
THROW_NOTHING
{
memtrace
::
traced_delete
(
p
,
FDELETEARR
);
}
/* Visual C++ 2012 miatt kell, mert háklis, hogy nincs megfelelő delete, bár senki sem használja */
/* Visual C++ 2012 miatt kell, mert háklis, hogy nincs megfelelő delete, bár senki sem használja */
void
operator
delete
(
void
*
p
,
int
,
const
char
*
)
THROW_NOTHING
{
void
operator
delete
(
void
*
p
,
int
,
const
char
*
)
THROW_NOTHING
{
...
@@ -534,4 +541,4 @@ START_NAMESPACE
...
@@ -534,4 +541,4 @@ START_NAMESPACE
int
atexit_class
::
err
=
0
;
int
atexit_class
::
err
=
0
;
#endif
#endif
END_NAMESPACE
END_NAMESPACE
#endif
#endif
\ No newline at end of file
diamond/memtrace.h
View file @
49821d94
...
@@ -5,7 +5,7 @@ Keszitette: Peregi Tamas, BME IIT, 2011
...
@@ -5,7 +5,7 @@ Keszitette: Peregi Tamas, BME IIT, 2011
Kanari: Szeberenyi Imre, 2013.,
Kanari: Szeberenyi Imre, 2013.,
VS 2012: Szeberényi Imre, 2015.,
VS 2012: Szeberényi Imre, 2015.,
mem_dump: 2016.
mem_dump: 2016.
inclue-ok: 2017., 2018.
2019.
inclue-ok: 2017., 2018.
, 2019., 2021.
*********************************/
*********************************/
#ifndef MEMTRACE_H
#ifndef MEMTRACE_H
...
@@ -153,6 +153,13 @@ END_NAMESPACE
...
@@ -153,6 +153,13 @@ END_NAMESPACE
#include <map>
#include <map>
#include <algorithm>
#include <algorithm>
#include <functional>
#include <functional>
#include <memory>
#include <iomanip>
#include <locale>
#include <typeinfo>
#include <ostream>
#include <stdexcept>
#include <ctime>
#endif
#endif
#ifdef MEMTRACE_CPP
#ifdef MEMTRACE_CPP
namespace
std
{
namespace
std
{
...
@@ -178,7 +185,7 @@ START_NAMESPACE
...
@@ -178,7 +185,7 @@ START_NAMESPACE
#define realloc(old,size) TRACEC(traced_realloc)(old,size,#size,__LINE__,__FILE__)
#define realloc(old,size) TRACEC(traced_realloc)(old,size,#size,__LINE__,__FILE__)
void
*
traced_realloc
(
void
*
old
,
size_t
size
,
const
char
*
size_txt
,
int
line
,
const
char
*
file
);
void
*
traced_realloc
(
void
*
old
,
size_t
size
,
const
char
*
size_txt
,
int
line
,
const
char
*
file
);
void
mem_dump
(
void
const
*
mem
,
size_t
size
,
FILE
*
fp
);
void
mem_dump
(
void
const
*
mem
,
size_t
size
,
FILE
*
fp
=
stdout
);
END_NAMESPACE
END_NAMESPACE
...
@@ -200,6 +207,10 @@ void * operator new[](size_t size) THROW_BADALLOC;
...
@@ -200,6 +207,10 @@ void * operator new[](size_t size) THROW_BADALLOC;
void
operator
delete
(
void
*
p
)
THROW_NOTHING
;
void
operator
delete
(
void
*
p
)
THROW_NOTHING
;
void
operator
delete
[](
void
*
p
)
THROW_NOTHING
;
void
operator
delete
[](
void
*
p
)
THROW_NOTHING
;
// sized delete miatt: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3536.html
void
operator
delete
(
void
*
p
,
size_t
)
THROW_NOTHING
;
void
operator
delete
[](
void
*
p
,
size_t
)
THROW_NOTHING
;
/* Visual C++ 2012 miatt kell, mert háklis, hogy nincs megfelelő delete, bár senki sem használja */
/* Visual C++ 2012 miatt kell, mert háklis, hogy nincs megfelelő delete, bár senki sem használja */
void
operator
delete
(
void
*
p
,
int
,
const
char
*
)
THROW_NOTHING
;
void
operator
delete
(
void
*
p
,
int
,
const
char
*
)
THROW_NOTHING
;
void
operator
delete
[](
void
*
p
,
int
,
const
char
*
)
THROW_NOTHING
;
void
operator
delete
[](
void
*
p
,
int
,
const
char
*
)
THROW_NOTHING
;
...
@@ -215,5 +226,8 @@ void operator delete[](void *p, int, const char *) THROW_NOTHING;
...
@@ -215,5 +226,8 @@ void operator delete[](void *p, int, const char *) THROW_NOTHING;
#endif
/*MEMTRACE_CPP*/
#endif
/*MEMTRACE_CPP*/
#endif
/*FROM_MEMTRACE_CPP*/
#endif
/*FROM_MEMTRACE_CPP*/
#endif
/*MEMCHECK*/
#else
#endif
/*MEMTRACE_H*/
#pragma message ( "MEMTRACE NOT DEFINED" )
#endif
/*MEMTRACE*/
#endif
/*MEMTRACE_H*/
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment