53
|
1 |
/*
|
|
2 |
* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description: xadebugtraceutility functionality
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#include <e32debug.h>
|
|
19 |
|
|
20 |
extern "C" {
|
|
21 |
|
|
22 |
void xa_print(const char* formatString)
|
|
23 |
{
|
|
24 |
RDebug::Printf(formatString);
|
|
25 |
}
|
|
26 |
|
|
27 |
void xa_print_1(const char* formatString, int a1)
|
|
28 |
{
|
|
29 |
RDebug::Printf(formatString, a1);
|
|
30 |
}
|
|
31 |
|
|
32 |
void xa_print_1_str(const char* formatString, const char* a1)
|
|
33 |
{
|
|
34 |
RDebug::Printf(formatString, a1);
|
|
35 |
}
|
|
36 |
|
|
37 |
void xa_print_2(const char* formatString, int a1, int a2)
|
|
38 |
{
|
|
39 |
RDebug::Printf(formatString, a1, a2);
|
|
40 |
}
|
|
41 |
|
|
42 |
void xa_print_2_str(const char* formatString, const char* a1, const char* a2)
|
|
43 |
{
|
|
44 |
RDebug::Printf(formatString, a1, a2);
|
|
45 |
}
|
|
46 |
|
|
47 |
void xa_print_3(const char* formatString, int a1, int a2, int a3)
|
|
48 |
{
|
|
49 |
RDebug::Printf(formatString, a1, a2, a3);
|
|
50 |
}
|
|
51 |
|
|
52 |
void xa_print_4(const char* formatString, int a1, int a2, int a3, int a4)
|
|
53 |
{
|
|
54 |
RDebug::Printf(formatString, a1, a2, a3, a4);
|
|
55 |
}
|
|
56 |
|
|
57 |
void xa_heap_total_alloc_print(const char* formatString)
|
|
58 |
{
|
|
59 |
RThread thread;
|
|
60 |
TInt cells = User::CountAllocCells();
|
|
61 |
TInt threadId = thread.Id();
|
|
62 |
RDebug::Printf(formatString);
|
|
63 |
RDebug::Print(_L("ThreadId[%d] Cells[%d]"),threadId, cells);
|
|
64 |
}
|
|
65 |
}
|
|
66 |
|
|
67 |
void xa_cppprint(const char* formatString)
|
|
68 |
{
|
|
69 |
RDebug::Printf(formatString);
|
|
70 |
}
|
|
71 |
|
|
72 |
void xa_cppprint_1(const char* formatString, int a1)
|
|
73 |
{
|
|
74 |
RDebug::Printf(formatString, a1);
|
|
75 |
}
|
|
76 |
|
|
77 |
void xa_cppprint_2(const char* formatString, int a1, int a2)
|
|
78 |
{
|
|
79 |
RDebug::Printf(formatString, a1, a2);
|
|
80 |
}
|