Make prof to work in a transparent way

This commit is contained in:
Francisco Javier Trujillo Mata
2024-07-14 11:27:09 +02:00
parent 8e122ce65b
commit ea9d5cf9cd
6 changed files with 22 additions and 29 deletions

View File

@@ -11,7 +11,7 @@ CFLAGS = @PSPSDK_CFLAGS@ -std=gnu99 -Wall -Wmissing-prototypes
CCASFLAGS = $(CFLAGS) -I$(top_srcdir)/src/base -I$(top_srcdir)/src/kernel
libpspprofincludedir = @PSPSDK_INCLUDEDIR@
libpspprofinclude_HEADERS = pspprof.h
libpspprofinclude_HEADERS =
lib_LIBRARIES = libpspprof.a
libpspprof_a_SOURCES = prof.c mcount.s

View File

@@ -78,7 +78,7 @@ extern int _ftext;
extern int _etext;
/* forward declarations */
void gprof_cleanup(void);
void __gprof_cleanup(void);
void __mcount(unsigned int, unsigned int);
static SceUInt timer_handler(SceUID uid, SceKernelSysClock *c1, SceKernelSysClock *c2, void *common);
@@ -156,7 +156,7 @@ static void initialize()
Called from atexit() handler; will dump out a host:gmon.out file
with all collected information.
*/
void gprof_cleanup()
void __gprof_cleanup()
{
FILE *fp;
int i;

View File

@@ -1,24 +0,0 @@
/*
* PSP Software Development Kit - https://github.com/pspdev
* -----------------------------------------------------------------------
* Licensed under the BSD license, see LICENSE in PSPSDK root for details.
*
* pspprof.h - Prototypes for the profiler library
*
* Copyright (c) 2006 Urchin
*
*/
#ifndef __PSPPROF_H__
#define __PSPPROF_H__
#ifdef __cplusplus
extern "C" {
#endif
void gprof_cleanup();
#ifdef __cplusplus
}
#endif
#endif /* __PSPPROF_H__ */