1 2004-01-13 Martin Baulig <martin@ximian.com>
3 * ChangeLog, MonoSymbolTable.cs: Reviewed Ben's patches. For
4 those which are not ok, I'll add detailed comments to the source
7 2003-12-28 Ben Maurer <bmaurer@users.sourceforge.net>
9 [Revision 1.41, not approved. Martin]
10 * MonoSymbolTable.cs (MethodEntry): kill more
13 2003-12-28 Ben Maurer <bmaurer@users.sourceforge.net>
15 [Revision 1.40, not approved. Martin]
16 * MonoSymbolTable.cs (MethodEntry): Remove the
17 SourceFileIndex field, we already have the info.
19 2003-12-28 Ben Maurer <bmaurer@users.sourceforge.net>
21 [Revision 1.39, approved. Martin]
22 * MonoSymbolTable.cs: Don't make the MethodIndexEntry
23 part of the method entry class, because it just
26 2003-12-28 Ben Maurer <bmaurer@users.sourceforge.net>
28 [Revisions 1.37 and 1.38; not approved. Martin]
29 * MonoSymbolTable.cs (MethodEntry.BuildLineNumberTable): Removed.
31 * MonoSymbolTable.cs, MonoSymbolWriter.cs: Use
32 fewer arrays, dont use arraylists with structs.
34 2003-12-27 Ben Maurer <bmaurer@users.sourceforge.net>
36 * MonoSymbolFile.cs: Much, much better string writing.
38 2003-12-20 Ben Maurer <bmaurer@users.sourceforge.net>
40 [Revision 1.36, approved. Martin]
41 * MonoSymbolTable.cs: Fewer StringBuilder allocs.
43 2003-12-08 Zoltan Varga <vargaz@freemail.hu>
45 * MonoSymbolWriter.cs: Create ArrayLists only when needed.
47 2003-12-07 Ben Maurer <bmaurer@users.sourceforge.net>
49 [Revision 1.35, approved. Martin]
50 * MonoSymbolTable.cs: It is faster to do a linear search
51 than it is to make a hashtable. Even though the linear
52 search is O(n^2) while the hashtable is O(n), the allocation
53 cost for a hashtable is *very* high, especially when only
54 a few members will be added.
56 2003-09-06 Martin Baulig <martin@ximian.com>
58 * MonoSymbolFile.cs: Removed debugging output.
60 2003-08-05 Martin Baulig <martin@ximian.com>
62 * MonoSymbolTable.cs (MethodEntry.Index): New public field.
64 2003-06-27 Zoltan Varga <vargaz@freemail.hu>
66 * MonoSymbolWriter.cs: Enable calling of DefineDocument multiple
67 times with the same URL.
69 2003-06-10 Zoltan Varga <vargaz@freemail.hu>
71 * MonoSymbolFile.cs: Fix off-by-one error.
73 2003-03-22 Martin Baulig <martin@ximian.com>
75 * MonoSymbolTable.cs (MethodEntry.LocalNamesAmbiguous): New public
76 field. Specifies whether two local variables have the same name.
78 2003-03-13 Martin Baulig <martin@ximian.com>
80 Added basic support for lexical scopes. This is just to tell a
81 debugger that a local variable is only available in a specific
82 lexical scope and that another variable of the same name may exist
83 in another lexical scope. See debugger/test/TestLexicalScope.cs
86 * MonoSymbolTable.cs (LexicalScopeEntry): New class.
87 (LocalVariableEntry): Added `BlockIndex' field which specifies the
88 lexical scope of this variable.
90 * MonoSymbolWriter.cs (SourceBlock): Removed, we're now using
91 LexicalScopeEntry instead.
93 2003-02-22 Martin Baulig <martin@ximian.com>
95 * MonoSymbolTable.cs: Incremented version number.
97 2003-02-22 Martin Baulig <martin@ximian.com>
99 * MonoSymbolFile.cs (MonoSymbolFile.FindMethod): Fixed a bug.
100 (MonoSymbolFile.MethodLookup): New method.
102 2003-02-18 Martin Baulig <martin@ximian.com>
104 * MonoSymbolFile.cs (MonoSymbolFile.GetMethod): Added overloaded
105 version which takes a MethodBase.
107 2003-02-18 Martin Baulig <martin@ximian.com>
109 * MonoSymbolTable.cs (MethodIndexEntry): New public struct.
111 * MonoSymbolFile.cs (MonoSymbolFile.GetMethodByToken): New method.
113 2003-02-18 Martin Baulig <martin@ximian.com>
115 * MonoSymbolFile.cs (MonoSymbolFile.Assembly): New public property.
117 * MonoSymbolTable.cs (MethodEntry.MethodBase): New public property.
118 (MethodEntry.LocalTypes): New public variable.
120 2003-02-18 Martin Baulig <martin@ximian.com>
122 * MonoSymbolFile.cs (MethodEntry.ThisTypeIndex): Renamed to
123 ClassTypeIndex; provide this for all methods so we can get the
124 class of static methods.
126 2003-02-10 Nick Drochak <ndrochak@gol.com>
128 * Mono.CSharp.Debugger.build: passing the /r using an 'arg' node works.
129 The <include> node wasn't getting to the compiler. This fixes build
132 * MonoSymbolFile.cs: Qualify which Min method. Fixes build breakage
135 2003-02-09 Martin Baulig <martin@ximian.com>
137 * MonoSymbolWriter.cs (MonoSymbolWriter.ctor): We don't need the
138 `mbuilder_array' anymore.
140 2003-02-09 Martin Baulig <martin@ximian.com>
142 * MonoSymbolWriter.cs (SourceFile): Derive from SourceFileEntry.
143 (SourceBlock): We don't need source lines here.
144 (SourceMethod): We're always constructed with source info.
146 * MonoSymbolTable.cs: Added support for namespaces.
147 (NamespaceEntry): New struct.
148 (SourceFileEntry.DefineNamespace): New method.
149 (MethodEntry.BuildLineNumberTable): The table is already sorted,
150 so we don't need to do this here.
152 2003-02-09 Martin Baulig <martin@ximian.com>
154 * IMonoSymbolWriter.cs: Ooops, I forgot to remove this.
156 2003-02-08 Martin Baulig <martin@ximian.com>
158 * MonoSymbolDocumentWriter.cs: Removed.
160 * MonoSymbolWriter.cs (SourceFile): Implement ISymbolDocumentWriter.
162 2003-02-08 Martin Baulig <martin@ximian.com>
164 * MonoSymbolFile.cs (GetMethodSource): New public method.
165 (FindMethod): Return the correct index.
167 2003-02-07 Martin Baulig <martin@ximian.com>
169 * MonoSymbolFile.cs (Methods, Sources): New public properties.
171 2003-02-07 Martin Baulig <martin@ximian.com>
173 * MonoSymbolFile.cs (MonoSymbolFile.ReadSymbolFile): New public
174 static method, returns null (without throwing an exception) if the
175 assembly doesn't have any debugging info.
177 2003-02-07 Martin Baulig <martin@ximian.com>
179 * MonoSymbolWriter.cs (MonoSymbolWriter.Initialize): Removed the
180 custom initialization function.
182 * MonoSymbolTableWriter.cs: Removed; the code is now in
183 MonoSymbolFile.cs and MonoSymbolWriter.cs.
185 2003-02-07 Martin Baulig <martin@ximian.com>
187 * MonoSymbolFile.cs: The symbol file is now a resource in the
188 assembly instead of a separate file.
190 * MonoSymbolTable.cs: Did a few more cleanups, sort the line
191 number table and remove duplicate line numbers.
193 2003-02-05 Martin Baulig <martin@ximian.com>
195 Modified the symbol file format to speed up method looks by name
196 and cleaned this up a lot.
198 * MonoSymbolFile.cs: New public class. This is now a public class
199 and writes and reads the symbol file.
201 * IMonoBinaryReader.cs: Removed.
203 * MonoSymbolTable.cs: Set version number to 29.
205 2003-01-17 Zoltan Varga <vargaz@freemail.hu>
207 * MonoSymbolWriter.cs (OpenMethod): Make it work on constructors.
209 2002-10-13 Martin Baulig <martin@gnome.org>
211 * MonoSymbolTable.cs: Set version number to 28.
212 (SourceFileEntry): Read the methods when they're needed.
213 (MethodSourceEntry): Made this a struct, not a class.
215 2002-10-13 Martin Baulig <martin@gnome.org>
217 * MonoSymbolTable.cs: Set version number to 27. Added a source
218 file table which is used to search a method by source file + line number.
220 2002-09-21 Martin Baulig <martin@gnome.org>
222 * MonoSymbolTable.cs: Set version number to 26. Removed all the dynamic
223 stuff, this library now just deals with the compiler generated symbol table.
224 The dynamic stuff is private between the JIT and the debugger.
226 2002-09-21 Martin Baulig <martin@gnome.org>
228 * MonoSymbolTable.cs: Set version number to 25. Added information about
231 2002-09-20 Martin Baulig <martin@gnome.org>
233 * MonoSymbolTable.cs: Set version number to 24. Added a type index
234 table. Write the type of a local variable or a parameter as an index
237 2002-09-20 Martin Baulig <martin@gnome.org>
239 * IMonoSymbolWriter.cs: Remove all the unused interfaces.
241 2002-09-20 Martin Baulig <martin@gnome.org>
243 * MonoSymbolTable.cs: Set version number to 23, include the size
246 2002-09-20 Martin Baulig <martin@gnome.org>
248 * MonoSymbolTable.cs: Set version number to 22. Provide information
249 about parameters and local variables.
251 2002-09-20 Martin Baulig <martin@gnome.org>
253 * IMonoSymbolWriter.cs: Use fullly qualified name for
254 System.Diagnostics.SymbolStore.ISymbolWriter rather than `using' this
255 namespace. This allows us to use the name `ISymbolWriter' in our own
258 2002-09-18 Martin Baulig <martin@gnome.org>
260 * MonoSymbolTable.cs: Set version number to 21. Encode the source file
261 as a 4-byte length field followed by the UTF8 encoded string.
263 2002-09-18 Martin Baulig <martin@gnome.org>
265 * IMonoBinaryReader.cs: New interface.
267 * MonoSymbolTable.cs: Use IMonoBinaryReader instead of binary reader.
269 2002-09-16 Martin Baulig <martin@gnome.org>
271 * MonoSymbolTable.cs: Set version number to 20.
273 2002-09-14 Martin Baulig <martin@gnome.org>
275 * MonoSymbolWriter.cs, IMonoSymbolWriter.cs, MonoSymbolTableWriter.cs:
276 Make all classes and interfaces which don't need to be public internal.
278 2002-09-14 Martin Baulig <martin@gnome.org>
280 * MonoSymbolTable.cs: Use only CLS-compliant types here, bumped version
283 * MonoSymbolTableReader.cs: Removed, this is now in the debugger.
285 2002-09-03 Martin Baulig <martin@gnome.org>
287 * AssemblerWriterI386.cs, IAssemblerWriter.cs, MonoDwarfFileWriter.cs,
288 README, README.relocation-table, csharp-lang.[ch], gdb-csharp-support.patch,
289 gdb-variable-scopes.patch: Removed.
291 2002-09-03 Martin Baulig <martin@gnome.org>
293 * MonoSymbolTableReader.cs (MonoSymbolTableReader.ImageFile): New
296 * MonoSymbolTable.cs: Bumped version number to 18.
298 2002-08-27 Martin Baulig <martin@gnome.org>
300 * MonoSymbolTable.cs (MethodAddress): Removed `TrampolineAddress'.
302 2002-08-27 Martin Baulig <martin@gnome.org>
304 * MonoSymbolTable.cs: Changed the file format in a way that allows us
305 open it read-only and to use a specially malloced area for all the
308 2002-08-25 Martin Baulig <martin@gnome.org>
310 * MonoSymbolTableReader.cs: New file. This is the reader for the
311 new symbol file format.
313 2002-08-24 Martin Baulig <martin@gnome.org>
315 * MonoSymbolTable.cs, MonoSymbolTableWriter.cs: New files. This
316 creates a binary application.dbg file which will be used by the
317 JIT to display source lines for exceptions.
319 * list.unix: Disabled the dwarf file writer in the build.
321 2002-08-23 Martin Baulig <martin@gnome.org>
323 * MonoSymbolWriter.cs (MonoSymbolWriter.Initialize): Added
324 assembly name argument. Since the symbol writer needs to read the
325 final assembly, we need to give it its full pathname.
327 2002-08-23 Martin Baulig <martin@gnome.org>
329 * makefile.gnu, list.unix: Added.
331 2002-07-05 Martin Baulig <martin@gnome.org>
333 * MonoDwarfFileWriter.cs: Added support for types in referenced assemblies.
335 2002-07-05 Martin Baulig <martin@gnome.org>
337 * MonoDwarfFileWriter.cs: Added support for arrays.
339 * gdb-csharp-support.patch: Updated.
341 2002-06-29 Martin Baulig <martin@gnome.org>
343 * MonoDwarfFileWriter.cs (DieInheritance): Make this actually work.
345 2002-06-29 Martin Baulig <martin@gnome.org>
347 * MonoDwarfFileWriter.cs, MonoSymbolWriter.cs: Put all TAG_subprogram's into their
348 corresponding struct/class declarations.
350 2002-06-28 Martin Baulig <martin@gnome.org>
352 * gdb-csharp-support.patch: Updated.
354 2002-06-28 Martin Baulig <martin@gnome.org>
356 * MonoDwarfFileWriter.cs: Use a TAG_string_type when we're using GNU extensions.
357 Make static struct/class fields actually work. Provide a TAG_typedef for struct's
360 2002-05-30 Martin Baulig <martin@gnome.org>
362 * IMonoSymbolWriter (IMonoSymbolWriter): Added custom `Initialize' method.
364 * MonoSymbolWriter.cs (Initialize): The ISymbolWriter's `Initialize' method
365 is no longer supported and throws an exception.
366 (Initialize (string, string[])): New custom initialization function.
368 * MonoDwarfFileWriter.cs (DwarfFileWriter): Added `string[] args' argument
369 to the constructor to pass command line arguments.
371 * gdb-csharp-support.patch: Updated for GDB 5.2.
373 2002-05-30 Martin Baulig <martin@gnome.org>
375 * MonoSymbolWriter.cs (MonoSymbolWriter): The constructor now get's the
376 AssemblyBuilder's `methods' array as third argument.
377 (OpenMethod): Use this array to get the method builder rather than using an
379 (get_method_builder): Removed this interncall.
381 2002-05-25 Martin Baulig <martin@gnome.org>
383 * MonoDwarfFileWriter.cs: Finished the type rewrite, put back strings and arrays.
385 2002-05-24 Martin Baulig <martin@gnome.org>
387 * IMonoSymbolWriter.cs (ISourceMethod): Added `FullName' and `Parameters'.
388 (ITypeHandle): New interface.
390 * DwarfFileWriter.cs: Largely reorganized the type writing code. Types are
391 now represented by ITypeHandle objects which are stored in a per-dwarf-writer
392 hash table. At the moment, all types still need to be in one compile unit due
393 to lacking support in gdb - but this new type code here already supports this.
395 * MonoSymbolWriter.cs: Moved all the subclasses to the top-level and made them
396 public, cleaned up the code, put everything into one compile unit.
397 (DefineLocalVariable): Added a version of this function which takes useful args.
399 2002-05-22 Martin Baulig <martin@gnome.org>
401 * IMonoSymbolWriter.cs (IMonoSymbolWriter): Added `Sources' and `Methods'
404 * MonoDwarfFileWriter.cs (WriteSymbolTable): New public method. Moved the
405 code that writes the "mono_line_numbers" section here from the LineNumberEngine.
407 2002-05-22 Martin Baulig <martin@gnome.org>
409 * IMonoSymbolWriter.cs (IVariable): Replaced Token with `ISourceMethod Method'.
411 * MonoSymbolWriter.cs (MonoSymbolWriter): The constructor now has an additional
412 ModuleBuilder argument.
413 (OpenMethod): Immediately call the `get_method' interncall to get the MethodBase
414 from the token, then store the MethodBase instead of the token. The token may
415 still change during the metadata library's fixup process.
416 (DoFixups): When the image has been written to disk, call the GetToken () method
417 on all MethodBuilders and all ConstructorBuilders to get the final metadata tokens.
419 2002-05-22 Martin Baulig <martin@gnome.org>
421 * AssemblerWriterI386.cs: Don't use GNU extensions and produce assembler
422 output which is free of comments and extra whitespaces so that it's suitable
425 2002-05-22 Martin Baulig <martin@gnome.org>
427 * IMonoSymbolWriter.cs (ISourceMethod): Replaced `MethodInfo MethodInfo' with
428 `MethodBase MethodBase' and added `Type ReturnType'. We're now correctly
429 dealing with constructors and not crashing anymore.
431 2002-05-21 Martin Baulig <martin@gnome.org>
433 * MonoDwarfFileWriter.cs: Write a special line number table which can be read
434 in by the metadata library to get line number information in backtraces.
436 2002-05-06 Martin Baulig <martin@gnome.org>
438 * MonoSymbolWriter.cs (MonoSymbolWriter.Close): Use Assembly.LoadFrom (), not
439 AppDomain.Load () to load the assembly.
441 2002-04-26 Martin Baulig <martin@gnome.org>
443 * gdb-csharp-support.patch: A patch for GDB (against the latest CVS version)
444 to implement C# support.
446 * csharp-lang.c, csharp-lang.h, csharp-mono-lang.c: Copy these into your GDB
447 source directory after applying the patch.
449 2002-04-26 Martin Baulig <martin@gnome.org>
451 * MonoDwarfFileWriter.cs (DieInternalString): Removed.
453 2002-04-25 Martin Baulig <martin@gnome.org>
455 * MonoDwarfFileWriter.cs: Reflect latest MonoString changes.
457 2002-04-13 Martin Baulig <martin@gnome.org>
459 * IMonoSymbolWriter.cs (ISourceBlock): Added `Blocks' property and `AddBlock'
460 method to support nested blocks.
462 * MonoSymbolWriter.cs: Correctly handle nested blocks.
464 * MonoDwarfFileWriter.cs (DieMember): Provide info for all fields, not just for
465 public ones; also added DW_AT_accessibility.
466 (DieVariable): Reflected latest debug-symfile.c changes.
468 2002-04-12 Martin Baulig <martin@gnome.org>
470 * gdb-variable-scopes.patch: A patch for GDB (against the latest CVS version)
471 to implement variable lifetimes.
473 2002-04-12 Martin Baulig <martin@gnome.org>
475 * MonoDwarfFileWriter.cs (DieVariable): Provide info about the variable's
476 lifetime using DW_AT_begin_scope and a new baulig extension DW_AT_end_scope.
478 2002-03-29 Martin Baulig <martin@gnome.org>
480 * AssemblerWriterI386.cs: Rewrote most of the string output function, do the
481 number->string conversion manually. It's now taking about 15 seconds to write
482 a symbol file for MCS, no longer more than a minute.
484 * MonoDwarfFileWriter.cs: Added some profiling code, speeded things up, fixed
487 2002-03-25 Martin Baulig <martin@gnome.org>
489 * MonoDwarfFileWriter.cs (CreateType): Return a `DieType'.
490 (RegisterType): Add the type to the type hash before creating dependency types
491 so we don't get recursion loops.
492 (RegisterPointerType): New func to register a "pointer to type" type.
493 (DieTypeDef, DiePointerType, DieArrayType, DieStringType, DieClassType): New
494 types; added support for strings, arrays and basic support for classes.
496 2002-03-24 Martin Baulig <martin@gnome.org>
498 * IMonoSymbolWriter.cs: Killed all methods in this interface, no longer needed.
500 * MonoSymbolWriter.cs (MonoSymbolWriter): The constructor now takes a string
501 argument which is the full pathname of the assembly - you must call Close()
502 after the assembly has been written to disk since the symbol writer needs to
503 load the finished assembly to get its metadata.
505 * MonoDwarfFileWriter.cs: Added support for enums and structs.
507 2002-03-24 Martin Baulig <martin@gnome.org>
509 * MonoDwarfFileWriter.cs: Added support for method parameters.
511 2002-03-24 Martin Baulig <martin@gnome.org>
513 * IMonoSymbolWriter.cs (IMonoSymbolWriter): Removed my custom OpenMethod(),
514 we're now using the ISymbolWriter's method.
515 (IVariable): Added `byte[] Signature' property.
517 * MonoSymbolWriter.cs (SetAssembly): New method. This must be called before
518 Close(); the assembly parameter is the already-written assembly, ie. it must
519 contain the full metadata.
520 (OpenMethod): Only take the token argument and set MethodInfo later in DoFixups.
521 (SetMethodSourceRange): You must call this function to tell the symbol writer
522 in which source file the method is defined.
523 (DefineLocal): Store the signature in the local.
524 (DoFixups): Use two new interncalls to set the SourceMethod's MethodInfo field
525 and the LocalVariable's Type field.
527 2002-03-23 Martin Baulig <martin@gnome.org>
529 * IMonoSymbolWriter.cs (ISourceBlock): New interface.
530 (ILocalVariable): Renamed this interface to IVariable.
531 (IVariable): Added Line, Type, Token.
532 (ILocalVariable, IMethodParameter): New interfaces, derive from IVariable.
533 (ISourceMethod): Added Blocks. Renamed FirstLine and LastLine to Start and End,
534 changed their type to ISourceLine. Removed CodeSize.
535 (ISourceLine): Renamed Line to Row, added Column. Added OffsetType and Offset.
537 * MonoDwarfFileWriter.cs (MonoDwarfFileWriter.DieLexicalBlock): New class.
538 (MonoDwarfFileWriter.DieMethodVariable): New class.
540 * MonoSymbolWriter.cs (OpenScope, CloseScope): Implemented.
541 Reflected latest IMonoSymbolWriter interface changes.
543 2002-03-20 Martin Baulig <martin@gnome.org>
545 * IAssemblerWriter.cs: New interface.
547 * AssemblerWriterI386.cs: New class.
549 * MonoDwarfFileWriter.cs: Use the IAssemblerWriter interface to make this class
550 platform and assembler independent.
552 2002-03-20 Martin Baulig <martin@gnome.org>
554 * IMonoSymbolWriter.cs (ISourceMethod): Added FirstLine, LastLine, CodeSize and
557 * MonoDwarfFileWriter.cs: Implemented line number support.
559 2002-03-19 Martin Baulig <martin@gnome.org>
561 * IMonoSymbolWriter.cs (ISourceFile, ISourceMethod, ISourceLine, ILocalVariable):
564 * IMonoSymbolWriter.cs (OpenMethod): Take a System.Reflection.MethodInfo, not
567 2002-03-19 Martin Baulig <martin@gnome.org>
569 This is an implementation of the System.Diagnostics.SymbolStore.SymbolWriter
570 interface. It's still work in progress and not yet used anywhere.
572 There is some preliminary documentation in the source files and some more
573 docu in the README and README.relocation-table files.
575 * IMonoSymbolWriter.cs: New file.
576 * MonoDwarfFileWriter.cs: New file.
577 * MonoSymbolDocumentWriter.cs: New file.
578 * MonoSymbolWriter.cs: New file.
580 * README, README.relocation-table: Documentation.