Hi, Jens, I found the endless loop reason now.
:lol:
file: D:\\kernel\\linux-2.6.35.7\\drivers\\scsi\\esp_scsi.h
line:355
dma_addr_t (*map_single)(struct esp *esp, void *buf,
size_t sz, int dir);
#0 00000000 Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1006)
#1 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#2 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#3 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#4 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#5 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#6 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#7 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#8 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#9 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#10 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#11 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#12 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#13 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#14 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#15 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#16 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#17 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#18 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#19 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#20 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#21 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#22 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#23 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#24 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#25 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#26 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#27 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
#28 65EE93CA Tokenizer::DoGetToken(this=0xc7739b0) (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1116)
#29 65EE9565 Tokenizer::MacroReplace(this=0xc7739b0, str="dma_addr_t") (D:\DengYC\CodeBlocks-svn\src\plugins\codecompletion\parser\tokenizer.cpp:1143)
The token is "dma_addr_t", and the m_Type is " dma_addr_t".
In here:
file = "D:\\kernel\\linux-2.6.35.7\\arch\\x86\\include\\asm\\types.h"
line = 4
#ifndef _ASM_X86_TYPES_H
#define _ASM_X86_TYPES_H
#define dma_addr_t dma_addr_t
#include <asm-generic/types.h>
It is the endless loop cause.
Seems to work for kernel 2.6.35 now:
Project 'test' parsing stage done (30447 total parsed files, 1313666 tokens in 9 minute(s), 26.239 seconds).
but if I close the project and reopen it (without closing C::B) the amount of used memory increases by about 100~200 MB every time.
And 2.6.29 kernel crashes with a segfault.
Here is a full backtrace:
> bt full
#0 0x0000000000447790 in wxStringBase::GetStringData (this=0x21f0000036c) at /usr/include/wx-2.8/wx/string.h:265
No locals.
#1 0x00000000004478d2 in wxStringBase::length (this=0x21f0000036c) at /usr/include/wx-2.8/wx/string.h:412
No locals.
#2 0x0000000000447a94 in wxString::Len (this=0x21f0000036c) at /usr/include/wx-2.8/wx/string.h:745
No locals.
#3 0x00007fffe32c277b in Tokenizer::GetActualContextForMacro (this=0xf1d7010, tk=0x2a697210) at plugins/codecompletion/parser/tokenizer.cpp:1739
pos = 44
buffer = L"_flags& DST_TYPE_HAS_FW_1) msleep (100) ; else msleep (5) ; return 0 ; } EXPORT_SYMBOL (dst_comm_init) ; int write_dst (struct dst_state* state, u8* data, u8 len) { struct i2c_msg msg = { . addr = sta"...
data = 0x5200000128 <Address 0x5200000128 out of bounds>
maxBufferLen = 4096
p = 0x430000014c <Address 0x430000014c out of bounds>
alreadyReplaced = {
<wxStringBase> = {
static npos = 18446744073709551615,
m_pchData = 0x6f00000069 <Address 0x6f00000069 out of bounds>
}, <No data fields>}
i = 240518168671
normalArgs = {
m_nSize = 171798691872,
m_nCount = 493921239140,
m_pItems = 0x5f00000074,
m_autoSort = 103
}
actualArgs = {
m_nSize = 433791697012,
m_nCount = 137438953513,
m_pItems = 0x200000007b,
m_autoSort = 105
}
actualContext = {
<wxStringBase> = {
static npos = 18446744073709551615,
m_pchData = 0x7400000075 <Address 0x7400000075 out of bounds>
}, <No data fields>}
actualContext = {
<wxStringBase> = {
static npos = 18446744073709551615,
m_pchData = 0x3c00000020 <Address 0x3c00000020 out of bounds>
}, <No data fields>}
#4 0x0000004900000044 in ?? ()
No symbol table info available.
#5 0x0000004100000053 in ?? ()
No symbol table info available.
#6 0x0000004c00000042 in ?? ()
No symbol table info available.
#7 0x0000002c00000045 in ?? ()
No symbol table info available.
#8 0x0000004e00000020 in ?? ()
No symbol table info available.
#9 0x0000005f0000004f in ?? ()
No symbol table info available.
#10 0x0000004500000044 in ?? ()
No symbol table info available.
#11 0x000000410000004c in ?? ()
No symbol table info available.
#12 0x0000002900000059 in ?? ()
No symbol table info available.
#13 0x0000003c00000020 in ?? ()
No symbol table info available.
#14 0x0000003000000020 in ?? ()
No symbol table info available.
#15 0x0000002000000029 in ?? ()
No symbol table info available.
#16 0x000000200000007b in ?? ()
No symbol table info available.
#17 0x0000007000000064 in ?? ()
No symbol table info available.
#18 0x0000006900000072 in ?? ()
No symbol table info available.
#19 0x000000740000006e in ?? ()
No symbol table info available.
#20 0x000000200000006b in ?? ()
No symbol table info available.
#21 0x0000007600000028 in ?? ()
No symbol table info available.
#22 0x0000007200000065 in ?? ()
No symbol table info available.
#23 0x0000006f00000062 in ?? ()
No symbol table info available.
#24 0x0000006500000073 in ?? ()
No symbol table info available.
#25 0x000000200000002c in ?? ()
No symbol table info available.
#26 0x0000005300000044 in ?? ()
No symbol table info available.
#27 0x0000005f00000054 in ?? ()
No symbol table info available.
#28 0x0000005200000045 in ?? ()
No symbol table info available.
#29 0x0000004f00000052 in ?? ()
No symbol table info available.
#30 0x0000002c00000052 in ?? ()
No symbol table info available.
#31 0x0000003100000020 in ?? ()
No symbol table info available.
#32 0x000000200000002c in ?? ()
No symbol table info available.
#33 0x0000006400000022 in ?? ()
No symbol table info available.
#34 0x0000007400000073 in ?? ()
No symbol table info available.
#35 0x000000670000005f in ?? ()
No symbol table info available.
#36 0x0000006900000070 in ?? ()
No symbol table info available.
#37 0x0000005f0000006f in ?? ()
No symbol table info available.
#38 0x000000750000006f in ?? ()
No symbol table info available.
#39 0x0000006200000074 in ?? ()
No symbol table info available.
#40 0x0000004500000020 in ?? ()
No symbol table info available.
#41 0x0000005200000052 in ?? ()
No symbol table info available.
#42 0x000000520000004f in ?? ()
No symbol table info available.
#43 0x0000002100000020 in ?? ()
No symbol table info available.
#44 0x0000002900000022 in ?? ()
No symbol table info available.
#45 0x0000003b00000020 in ?? ()
No symbol table info available.
#46 0x0000007200000020 in ?? ()
No symbol table info available.
#47 0x0000007400000065 in ?? ()
No symbol table info available.
#48 0x0000007200000075 in ?? ()
Cannot access memory at address 0x5effffffc8
No symbol table info available.
#49 0x000000200000006e in ?? ()
No symbol table info available.
#50 0x000000200000002d in ?? ()
No symbol table info available.
#51 0x0000002000000031 in ?? ()
No symbol table info available.
#52 0x000000200000003b in ?? ()
No symbol table info available.
#53 0x000000200000007d in ?? ()
No symbol table info available.
#54 0x0000006600000069 in ?? ()
No symbol table info available.
#55 0x0000002800000020 in ?? ()
No symbol table info available.
#56 0x0000007400000073 in ?? ()
No symbol table info available.
#57 0x0000007400000061 in ?? ()
No symbol table info available.
#58 0x0000002d00000065 in ?? ()
No symbol table info available.
#59 0x000000740000003e in ?? ()
No symbol table info available.
#60 0x0000007000000079 in ?? ()
No symbol table info available.
#61 0x00007fff00000065 in ?? ()
No symbol table info available.
#62 0x000000000f1d7010 in ?? ()
No symbol table info available.
#63 0x000000000000002e in ?? ()
No symbol table info available.
#64 0x00007fffdb977810 in ?? ()
No symbol table info available.
#65 0x00000000db9777e0 in ?? ()
No symbol table info available.
#66 0x0000045400000022 in ?? ()
No symbol table info available.
#67 0x000000000000002e in ?? ()
No symbol table info available.
#68 0x00000000000000bc in ?? ()
No symbol table info available.
#69 0x00007fffdb977870 in ?? ()
No symbol table info available.
#70 0x00007fffe32c236f in Tokenizer::ReplaceBufferForReparse (this=) at plugins/codecompletion/parser/tokenizer.cpp:1651
buffer = <error reading variable buffer (Cannot access memory at address 0x5effffffd0)>
bufLen = <error reading variable bufLen (Cannot access memory at address 0x5f00000010)>
p = <error reading variable p (Cannot access memory at address 0x5f00000000)>
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
Consider the following:
namespace {
const Z_GLC::Rectangle<int> game_rect;
void handle_ball_ball_collisions(Ball_manager *balls)
{
RectVector rects;
split_rect(rects, game_ //<< here
game_rect isn't shown by cc.
One more thing: why does function call tip disappears when the cc list spawns?
I can't access anymore the CC branch is the svn :
svn: URL 'svn://svn.berlios.de/codeblocks/branches/codecompletion_refactoring' doesn't exist
It works for trunk, not for this branch. Perhaps the branch have been commited ? :)
update CC method:
for the record:
In windows, if you use TortoiseSVN, you just right click on the old cc_branch working copy, then select the context menu item "switch", then put in the trunk address :
svn://svn.berlios.de/codeblocks/trunk
Done.
Then you are using the updated trunk now.
PS:
Not sure why "relocate" command does not works... Maybe the svn command : relocate and switch has different functionality.
Hello,
Using r6688 CC branch on Windows 7 x64.
Found the following issue, I hope I'm posting this in the correct thread:
Steps:
- Settings->Editor->Code Completion and Symbols browser page->C/C++ parser tab->Add button under Replacement tokens section
- add the following replacement token:
Key: BEGIN_NAMESPACE(CryptoPP)
Value: namespace CryptoPP{
- close CodeBlocks
- reopen CodeBlocks, it should crash with the following exception:
---------------------------
Exception
---------------------------
An exception has been raised!
The application encountered an error at E:\CodeBlocks\branches\codecompletion_refactoring\src\sdk\configmanager.cpp, on line 239.
The error message is:
TinyXML error: Error reading Attributes.
In file: C:\Users\Zadirion\AppData\Roaming\codeblocks\default.conf
At row 902, column: 33.
Code::Blocks Version revision 6688 (gcc 4.4.1, build: Oct 9 2010 11:48:56)
---------------------------
OK
---------------------------
I believe these are the offending lines added in default.conf?
<BEGIN_NAMESPACE(CryptoPP)>
<![CDATA[namespace CryptoPP{]]>
</BEGIN_NAMESPACE(CryptoPP)>
Perhaps they should be properly escaped when added to the xml.
Also, when are the CodeCompletion and Debugger branches scheduled for merge into trunk? CodeCompletion is finaly able to properly parse the CryptoPP library, and the debugger can finaly show me where the exception was thrown, along with a useful call stack. I can't use one branch or the other because both are very useful for an efficient developing session.
Thanks
Zadirion: trunk+CC are now merged in the debugger's branch, so the improvements in CC are now in the branch :)
Do you mean either the changes are already in r6688 or they are in the svn and I need to check out the latest revision and build from source?
Also, a bit off topic but I'm getting the following error during a debug session when I'm trying to step inside a CryptoPP function (more like a constructor but i don't think that's relevant):
Cannot open file: D:/testproject/../../testproject/third-party/cryptopp//cryptlib.h
I am noting that the "../../" in the path will evaluate to a paths above D:/ which doesn't really make any sense. I'm not sure where the relative paths come from so I can't remove them. Any ideas?
Thanks