Commit graph

40459 commits

Author SHA1 Message Date
Walter Bright
d5e31acc58 fix for bugzilla 2105 2008-12-10 03:07:11 +00:00
Sean Kelly
52ba4f7f76 I should just not code when I'm this tired :p Changed type type of _tlsstart and _tlsend back to int from size_t, since it's the address of these values that matters. 2008-12-08 21:24:30 +00:00
Sean Kelly
dcddcbcaea Moved the functionality in threadasm.S into the compiler runtime as tls.s. Not sure yet if these will be wrapped in an rt_ routine for use by the core lib. That decision may wait until more discussion is had regarding TLS for shared libraries. 2008-12-08 20:49:16 +00:00
Sean Kelly
7b05c34469 * Added threadasm.S to replace tls.s. The capital 's' allows C-style macros to be used in the file, which may come in handy.
* Cleaned up indentation and such in thread.d.
2008-12-08 20:30:57 +00:00
Sean Kelly
a3604ce22b Renaming tls.s to tls.S so macros can be used. 2008-12-08 19:48:51 +00:00
Walter Bright
c1c824fa0e got _tlsstart and _tlsend working for linux 2008-12-07 21:27:00 +00:00
Walter Bright
2d761755cc fix broken build 2008-12-07 07:55:57 +00:00
Walter Bright
540a4e89dc fix to scan tls 2008-12-07 06:33:12 +00:00
Sean Kelly
14d2788520 Fixed new build process on Linux (some .c files were being treated as .d files). 2008-12-06 00:02:21 +00:00
Sean Kelly
cb8d2b9c6b * Replaced "rt" package name for DMD runtime modules. Apparently, an import statement can include the package name for a local file, even if the local directory isn't in the import path via the expected package location. ie. it appears that if DMD detects that the package name of an import file matches the package name of the importing modules then it just looks in the current directory. Awesome.
* Changed the Linux build to use DMD's -lib feature as well.  Untested, but I'll do that shortly.
* Propagated the -lib build approach to the D 1.0 branch.
2008-12-05 20:27:00 +00:00
Walter Bright
91d3a15f1d use dmd's library building capability 2008-11-29 06:29:11 +00:00
Walter Bright
930b01381a added shared typeinfo 2008-11-29 05:53:46 +00:00
Sean Kelly
fc538fdd9b Added core.vararg for variadic argument handling. This seemed necessary, since varargs are a language feature. There should be no conflict with std.stdarg, etc, anyway. 2008-11-25 23:53:07 +00:00
Sean Kelly
a69c3f01ee * Small fix to a typo in trunk/cover.d
* Merged changes from trunk/cover to branches/D1.0/cover
2008-11-25 00:56:46 +00:00
Sean Kelly
b2e0c4245a * Removed -version=Posix from dmd.conf. This flag is now set automatically by DMD.
* Fixed code coverage feature such that the output files will be ./basename.lst instead of basename.d.lst located in their original path.  The previous 
behavior was breaking on linux where the install path is typically read-only, and should now match the old phobos code coverage feature.
2008-11-24 22:42:47 +00:00
Walter Bright
083bdcec14 cover.d does not produce output 2008-11-24 03:06:35 +00:00
Sean Kelly
5f2677cd45 * Removed "-debug" from the list of debug build flags. The purpose of debug builds is to test user code, not library code.
* Fixed an edit error that would have broken unit testing of druntime in trunk.
2008-11-21 23:08:16 +00:00
Sean Kelly
9410c94a3c * Auto type determination was broken in some unit tests. This has been fixed.
* The following new build options have been added:
    - release (default)
    - debug
    - unittest
* Debug libraries are now generated by the build-dmd scripts and have a "-d" appended to their name.  These libraries have both "-g" and "-debug" set to enable asserts and symbol info.
* Added unittest.d to run unit tests.
* Added test-dmd.bat to build and run unit tests on Win32.  A problem currently exists with this feature, and once it has been resolved a test-dmd.sh will be added as well.
2008-11-20 22:49:32 +00:00
Sean Kelly
516d1edbf1 Fixed the static data area range calculation. Previous behavior was causing only 1/4 of the static data area to be scanned by the GC. 2008-11-06 20:36:50 +00:00
Walter Bright
59f1d1cafd fix scope 2008-11-06 09:58:20 +00:00
Sean Kelly
4da2c92cc3 Changed D 2.0 runtime to account for 'this' being changed from a pointer to a reference. This update will only work with DMD 2.021 and above. 2008-11-05 00:40:16 +00:00
Sean Kelly
9cf860225c * Fixed the documentation for sleep().
* Changed the implementation of sleep() on Windows such that a yield will not be forced upon the user if they pass an interval that evaluates to zero.  For more information regarding Sleep(0), see the MSDN docs.
2008-11-05 00:35:42 +00:00
Sean Kelly
a7cd390c29 * Reclassified most runtime-generated errors as Errors rather than Exceptions. This involved both a parent reasignment and a name change. At this point, the only remaining Exception is UnicodeException.
* Renamed ArrayBoundsException to RangeError in an attempt to be more general.
* Renamed onArrayBoundsError callback to onRangeError to make handling of these conditions more general as well.  Ideally, this will allow the same callback to be used for other purposes in the future.
2008-10-31 23:13:27 +00:00
Sean Kelly
19d6adc486 Changed the package name for bitmanip. 2008-10-31 22:07:16 +00:00
Sean Kelly
95429f1f56 Fixed 64-bit prototype for dirent_r routine. 2008-10-29 21:22:29 +00:00
Sean Kelly
31c28edd96 Added static data segment support to the new Runtime.loadLibrary() features. This also replaces static data segment scanning for all apps by dropping rt_scanStaticData() in favor of a new initialization step that calls gc_addRange() for each static data segment. The upshot of this is that all GCs must track add/remove Root and Range calls so the info can be passed to a proxy if gc_setProxy() is called. See src/gc/stub/gc.d for a simple implementation of this. 2008-10-29 00:15:37 +00:00
Sean Kelly
30c428a710 First attempt at support for dynamic library loading and unloading. Currently, only Windows is supported, and information on static data ranges still needs to be passed to the application GC (see "TODO" in gc/basic and gc/stub). 2008-10-27 22:15:16 +00:00
Sean Kelly
db1536183f Removed stdc directory. This was moved to core/stdc. 2008-10-27 22:08:29 +00:00
Sean Kelly
c55599d072 * Moved sys into core.sys
* Moved stdc.posix into core.sys.posix
* Moved stdc into core.stdc
* Added initial support for Runtime.loadLibrary() and Runtime.unloadLibrary() in D2.  The same functions are exposed in D1, but they are stubbed out for the moment.  The basic library loading and unloading should theoretically work, but the GC handle swapping code still needs a look, etc.  I left the D1 version stubbed out to make finding GC diffs easier for when I look at the handle swapping code (which is in D2 but not D1).  Still not sure about the function naming either... may just switch to load() and unload().
2008-10-25 00:15:55 +00:00
Sean Kelly
9840b16488 Changed pthread_cleanup to properly account for platform differences. core.thread should now build with freebsd. 2008-10-21 23:40:18 +00:00
Walter Bright
4740931234 enable generation of gcstub.obj 2008-10-20 20:51:32 +00:00
Walter Bright
aad3bb955c restored support for setting gc handle 2008-10-20 05:01:16 +00:00
Sean Kelly
867558c18b Fixed a few build script issues on posix, including a bug in looking for some of the core modules in the wrong place, and a hack to eliminate filename collision with the dmd compiler runtime. This latter issue really needs to be addressed in a better way, but at this point my priority is just to get the build working. 2008-10-17 03:06:32 +00:00
Sean Kelly
5cc64a1812 Changed Thread.sleep() to accept a long with a tick resolution of 100 nanoseconds. This closes #9 2008-10-16 20:54:55 +00:00
Sean Kelly
88d00e1b9b No longer default-initializing a buffer which is immediately set via a function call. 2008-10-16 20:46:34 +00:00
Sean Kelly
11bfb05bb2 * Changed top-level exception class name from 'Exception' to 'Throwable'.
* Created a new class 'Exception' which derives from 'Throwable'.
* Created a new class 'Error' which derives from 'Throwable'.
* Moved core modules from the top level into a package named 'core'.
* Added onHiddenFuncError() routine to pass hidden function error handling from the runtime to core.exception.
* Renamed _d_getErrno to getErrno and moved it to src/common/stdc.  The idea is that druntime may eventually generate a lib for the stdc modules, and this definition is necessary.  The comparable function will have to be removed from Phobos as well.
* Moved the GC code into a package named 'gc', which is in accordance with the spec defined for druntime library integration (as yet unpublished).
2008-10-15 21:33:55 +00:00
Walter Bright
a8ed90f6e1 fix support for file/line 2008-10-13 21:39:33 +00:00
Sean Kelly
4b405b1432 Fixed import path override for library build on posix. 2008-10-13 19:55:46 +00:00
Sean Kelly
335d3d0409 Fixed a potential issue with building druntime. src/core will now be a part of the import path. This is necessary if any of the core modules import one another--not the case now, but better safe than sorry. 2008-10-13 19:44:27 +00:00
Sean Kelly
a0886be68b Fixed a build error on Linux. 2008-10-13 19:38:22 +00:00
Walter Bright
b75e2fe2ca add hidden function error support 2008-10-13 17:19:53 +00:00
Walter Bright
c0c2474a40 update readme.txt 2008-10-13 00:47:05 +00:00
Walter Bright
eb91542f26 restored Object.factory() 2008-10-12 20:03:44 +00:00
Walter Bright
844127aa90 renamed output library 2008-10-12 19:53:43 +00:00
Walter Bright
1cf88e803c fix it so it compiles 2008-10-12 01:53:37 +00:00
Sean Kelly
840f10020b Added _d_delarray_t and _d_allocmemory. 2008-10-10 21:49:12 +00:00
Sean Kelly
faec8478df Added Error alias for Exception as a placeholder until the exception hierarchy can be finalized. This should facilitate a batch update later on. 2008-10-10 18:59:32 +00:00
Sean Kelly
4f95a7eb0f Merged in changes from Phobos SVN. 2008-10-10 18:57:31 +00:00
Sean Kelly
aa7daf8302 Fixed eol-style for all source files. This closes #1 2008-10-08 05:49:34 +00:00
Sean Kelly
581546cdbf Fixed a few mistakes regarding invariance, etc, between D1 and D2. 2008-10-06 19:41:05 +00:00