- 11 Apr, 2005 1 commit
-
-
simonmar authored
Set the default minAllocAreaSize to 512k. Caches are bigger these days.
-
- 27 Mar, 2005 1 commit
-
-
panne authored
* Some preprocessors don't like the C99/C++ '//' comments after a directive, so use '/* */' instead. For consistency, a lot of '//' in the include files were converted, too. * UnDOSified libraries/base/cbits/runProcess.c. * My favourite sport: Killed $Id$s.
-
- 15 Mar, 2005 1 commit
-
-
sof authored
[mingw only]setProgName(): robustify by looking for the last '/' or '\\' in argv[0]. My copy of 'gdb' likes to use a mixture of the two, which causes a fatal error when trying to debug libHSrts_p.a. Other process-invoking apps/shells might be equally wavering when it comes to the use of slashes. Merge to STABLE.
-
- 03 Feb, 2005 1 commit
-
-
simonmar authored
Make setProgArgv() set the RTS's idea of the prog name too.
-
- 28 Jan, 2005 1 commit
-
-
simonmar authored
Rationalise the BUILD,HOST,TARGET defines. Recall that: - build is the platform we're building on - host is the platform we're running on - target is the platform we're generating code for The change is that now we take these definitions as applying from the point of view of the particular source code being built, rather than the point of view of the whole build tree. For example, in RTS and library code, we were previously testing the TARGET platform. But under the new rule, the platform on which this code is going to run is the HOST platform. TARGET only makes sense in the compiler sources. In practical terms, this means that the values of BUILD, HOST & TARGET may vary depending on which part of the build tree we are in. Actual changes: - new file: includes/ghcplatform.h contains platform defines for the RTS and library code. - new file: includes/ghcautoconf.h contains the autoconf settings only (HAVE_BLAH). This is so that we can get hold of these settings independently of the platform defines when necessary (eg. in GHC). - ghcconfig.h now #includes both ghcplatform.h and ghcautoconf.h. - MachRegs.h, which is included into both the compiler and the RTS, now has to cope with the fact that it might need to test either _TARGET_ or _HOST_ depending on the context. - the compiler's Makefile now generates stage{1,2,3}/ghc_boot_platform.h which contains platform defines for the compiler. These differ depending on the stage, of course: in stage2, the HOST is the TARGET of stage1. This was wrong before. - The compiler doesn't get platform info from Config.hs any more. Previously it did (sometimes), but unless we want to generate a new Config.hs for each stage we can't do this. - GHC now helpfully defines *_{BUILD,HOST}_{OS,ARCH} automatically in CPP'd Haskell source. - ghcplatform.h defines *_TARGET_* for backwards compatibility (ghcplatform.h is included by ghcconfig.h, which is included by config.h, so code which still #includes config.h will get the TARGET settings as before). - The Users's Guide is updated to mention *_HOST_* rather than *_TARGET_*. - coding-style.html in the commentary now contains a section on platform defines. There are further doc updates to come. Thanks to Wolfgang Thaller for pointing me in the right direction.
-
- 18 Nov, 2004 1 commit
-
-
tharris authored
Support for atomic memory transactions and associated regression tests conc041-048
-
- 12 Sep, 2004 1 commit
-
-
panne authored
Removed the annoying "Id" CVS keywords, they're a real PITA when it comes to merging...
-
- 03 Sep, 2004 1 commit
-
-
simonmar authored
Cleanup: all (well, most) messages from the RTS now go through the functions in RtsUtils: barf(), debugBelch() and errorBelch(). The latter two were previously called belch() and prog_belch() respectively. See the comments for the right usage of these message functions. One reason for doing this is so that we can avoid spurious uses of stdout/stderr by Haskell apps on platforms where we shouldn't be using them (eg. non-console apps on Windows).
-
- 13 Aug, 2004 1 commit
-
-
simonmar authored
Merge backend-hacking-branch onto HEAD. Yay!
-
- 22 Mar, 2004 1 commit
-
-
simonmar authored
change this message: <prog>: GHC not built for -prof to <prog>: not built for -prof Suggested by: Sven Panne.
-
- 18 Mar, 2004 1 commit
-
-
simonmar authored
Change the default max stack size (+RTS -K<n>) to 8M.
-
- 12 Nov, 2003 1 commit
-
-
sof authored
Tweaks to have RTS (C) sources compile with MSVC. Apart from wibbles related to the handling of 'inline', changed Schedule.h:POP_RUN_QUEUE() not to use expression-level statement blocks.
-
- 31 Oct, 2003 1 commit
-
-
sof authored
prog_name: use '\' as separator with mingw builds. merge to stable
-
- 17 Sep, 2003 1 commit
-
-
sof authored
usage_text[]: -k doc wibble
-
- 22 Aug, 2003 1 commit
-
-
sof authored
setupRtsFlags(): don't overwrite argv[0] with its basename: - argv[] may not point to writeable memory - System.Environment.getProgName strips off the 'dirname' portion anyway. - Not possible to get at the untransformed argv[0] from Haskell code, should such a need arise. Uses of prog_argv[0] within the RTS has now been replaced with prog_name, which is the basename of prog_argv[0].
-
- 21 Apr, 2003 1 commit
-
-
sof authored
drop curious *_debug_opts_prefix tables; no longer used
-
- 25 Mar, 2003 1 commit
-
-
sof authored
wibble wrt stgMallocBytes()
-
- 22 Feb, 2003 1 commit
-
-
sof authored
Clean up code&interfaces that deals with timers and asynchrony: - Timer.{c,h} now defines the platform-independent interface to the timing services needed by the RTS. Itimer.{c,h} + win32/Ticker.{c,h} defines the OS-specific services that creates/destroys a timer. - For win32 plats, drop the long-standing use of the 'multimedia' API timers and implement the ticking service ourselves. Simpler and more flexible. - Select.c is now solely for platforms that use select() to handle non-blocking I/O & thread delays. win32/AwaitEvent.c provides the same API on the Win32 side. - support threadDelay on win32 platforms via worker threads. Not yet compiled up on non-win32 platforms; will do once checked in.
-
- 28 Jan, 2003 1 commit
-
-
simonmar authored
Initialise prog_argc, prog_argv and rts_argc to sensible zero values just in case hs_init() is called without passing any arguments in.
-
- 23 Jan, 2003 1 commit
-
-
simonmar authored
- Add a new flag, -xt, which enables inclusion of TSOs in a heap profile. - Include large objects in heap profiles (except TSOs unless the -xt flag is given). - In order to make this work, I had to set the bd->free field of the block descriptor for a large object to the correct value. Previously, it pointed to the start of the block (i.e. the same as bd->start). I hope this doesn't have any other consequences; it looks more correct this way in any case.
-
- 19 Dec, 2002 1 commit
-
-
simonmar authored
comment wibble
-
- 11 Dec, 2002 1 commit
-
-
simonmar authored
Merge the eval-apply-branch on to the HEAD ------------------------------------------ This is a change to GHC's evaluation model in order to ultimately make GHC more portable and to reduce complexity in some areas. At some point we'll update the commentary to describe the new state of the RTS. Pending that, the highlights of this change are: - No more Su. The Su register is gone, update frames are one word smaller. - Slow-entry points and arg checks are gone. Unknown function calls are handled by automatically-generated RTS entry points (AutoApply.hc, generated by the program in utils/genapply). - The stack layout is stricter: there are no "pending arguments" on the stack any more, the stack is always strictly a sequence of stack frames. This means that there's no need for LOOKS_LIKE_GHC_INFO() or LOOKS_LIKE_STATIC_CLOSURE() any more, and GHC doesn't need to know how to find the boundary between the text and data segments (BIG WIN!). - A couple of nasty hacks in the mangler caused by the neet to identify closure ptrs vs. info tables have gone away. - Info tables are a bit more complicated. See InfoTables.h for the details. - As a side effect, GHCi can now deal with polymorphic seq. Some bugs in GHCi which affected primitives and unboxed tuples are now fixed. - Binary sizes are reduced by about 7% on x86. Performance is roughly similar, some programs get faster while some get slower. I've seen GHCi perform worse on some examples, but haven't investigated further yet (GHCi performance *should* be about the same or better in theory). - Internally the code generator is rather better organised. I've moved info-table generation from the NCG into the main codeGen where it is shared with the C back-end; info tables are now emitted as arrays of words in both back-ends. The NCG is one step closer to being able to support profiling. This has all been fairly thoroughly tested, but no doubt I've messed up the commit in some way.
-
- 05 Oct, 2002 1 commit
-
-
panne authored
Warning police #12: Multi-line string literals are uncool.
-
- 01 Oct, 2002 1 commit
-
-
simonmar authored
The help text for the -i profiling option was wrong: it claimed the argument was in milliseconds rather than seconds. MERGE TO STABLE
-
- 05 Aug, 2002 1 commit
-
-
simonmar authored
Overhaul the debugging flags. The old bitfield mechanism was a bit silly, so now instead of writing -D129 (the one I use most) you can now write -DSs. Each debugging option has a single character assigned to it, documented in the -? help text.
-
- 18 Jul, 2002 1 commit
-
-
simonmar authored
Remove a bogus test
-
- 17 Jul, 2002 1 commit
-
-
simonmar authored
Remove most #includes of system headers from Stg.h, and instead #include any required headers directly in each RTS source file. The idea is to (a) reduce namespace pollution from system headers that we don't need, (c) be clearer about dependencies on system things in the RTS, and (c) improve via-C compilation times (maybe). In practice though, HsBase.h #includes everything anyway, so the difference from the point of view of .hc source is minimal. However, this makes it easier to move to zero-includes if we wanted to (see discussion on the FFI list; I'm still not sure that's possible but at least this is a step in the right direction).
-
- 12 Dec, 2001 1 commit
-
-
simonmar authored
- Add a new type of restriction: -hC, which restricts to closures whose CCS contains the specified CCs *anywhere* (not just at the top). - Complain if the user tries to request both retainer and biographical profiling. We don't support both simultaneously, because they use the same header word in the closure. - Allow for the fact that the heap might contain some closures which don't have a valid retainer set during the heap census. The only known closures of this kind so far are DEAD_WEAK closures. - Some cruft-removal and renaming of functions to follow conventions.
-
- 03 Dec, 2001 1 commit
-
-
simonmar authored
Set the default heap profiling interval to something more sensible (100ms).
-
- 28 Nov, 2001 1 commit
-
-
simonmar authored
The curly braces around heap profile selectors are now optional (and deprecated). Two reasons: having to quote the options is a real PITA and gets even worse when trying to use them from a Makefile, and this also brings us closer to nhc's option format.
-
- 26 Nov, 2001 1 commit
-
-
simonmar authored
Profiling cleanup. This commit eliminates some duplication in the various heap profiling subsystems, and generally centralises much of the machinery. The key concept is the separation of a heap *census* (which is now done in one place only instead of three) from the calculation of retainer sets. Previously the retainer profiling code also did a heap census on the fly, and lag-drag-void profiling had its own census machinery. Value-adds: - you can now restrict a heap profile to certain retainer sets, but still display by cost centre (or type, or closure or whatever). - I've added an option to restrict the maximum retainer set size (+RTS -R<size>, defaulting to 8). - I've cleaned up the heap profiling options at the request of Simon PJ. See the help text for details. The new scheme is backwards compatible with the old. - I've removed some odd bits of LDV or retainer profiling-specific code from various parts of the system. - the time taken doing heap censuses (and retainer set calculation) is now accurately reported by the RTS when you say +RTS -Sstderr. Still to come: - restricting a profile to a particular biography (lag/drag/void/use). This requires keeping old heap censuses around, but the infrastructure is now in place to do this.
-
- 22 Nov, 2001 1 commit
-
-
simonmar authored
Retainer Profiling / Lag-drag-void profiling. This is mostly work by Sungwoo Park, who spent a summer internship at MSR Cambridge this year implementing these two types of heap profiling in GHC. Relative to Sungwoo's original work, I've made some improvements to the code: - it's now possible to apply constraints to retainer and LDV profiles in the same way as we do for other types of heap profile (eg. +RTS -hc{foo,bar} -hR -RTS gives you a retainer profiling considering only closures with cost centres 'foo' and 'bar'). - the heap-profile timer implementation is cleaned up. - heap profiling no longer has to be run in a two-space heap. - general cleanup of the code and application of the SDM C coding style guidelines. Profiling will be a little slower and require more space than before, mainly because closures have an extra header word to support either retainer profiling or LDV profiling (you can't do both at the same time). We've used the new profiling tools on GHC itself, with moderate success. Fixes for some space leaks in GHC to follow...
-
- 01 Oct, 2001 1 commit
-
-
simonmar authored
Allow default RTS options to be specified by linking in an object file which defines the symbol `ghc_rts_opts' to point to a string of RTS options. This is preferred to using defaultsHook(), if possible. Perhaps we could remove defaultsHook(). (won't work with DLL's; if we ever ressurrect them we'll have to deal with this somehow).
-
- 31 Aug, 2001 1 commit
-
-
sewardj authored
Properly handle the linker debugging (-D4096) before. MERGE TO STABLE BRANCH
-
- 14 Aug, 2001 1 commit
-
-
sewardj authored
Change the story about POSIX headers in C compilation. Until now, all C code in the RTS and library cbits has by default been compiled with settings for POSIXness enabled, that is: #define _POSIX_SOURCE 1 #define _POSIX_C_SOURCE 199309L #define _ISOC9X_SOURCE If you wanted to negate this, you'd have to define NON_POSIX_SOURCE before including headers. This scheme has some bad effects: * It means that ccall-unfoldings exported via interfaces from a module compiled with -DNON_POSIX_SOURCE may not compile when imported into a module which does not -DNON_POSIX_SOURCE. * It overlaps with the feature tests we do with autoconf. * It seems to have caused borkage in the Solaris builds for some considerable period of time. The New Way is: * The default changes to not-being-in-Posix mode. * If you want to force a C file into Posix mode, #include as the **first** include the new file ghc/includes/PosixSource.h. Most of the RTS C sources have this include now. * NON_POSIX_SOURCE is almost totally expunged. Unfortunately we have to retain some vestiges of it in ghc/compiler so that modules compiled via C on Solaris using older compilers don't break.
-
- 13 Aug, 2001 1 commit
-
-
simonmar authored
The '--' argument disables any further +RTS ... -RTS processing on the command line.
-
- 10 Aug, 2001 1 commit
-
-
simonmar authored
Fix bug with +RTS -P
-
- 08 Aug, 2001 1 commit
-
-
simonmar authored
Flag tweaks: +RTS -c now means "enable compaction all the time" (previously there was no way to do this *and* run without a maximum heap size). The heuristics for determining the generation sizes are also slightly better now.
-
- 07 Aug, 2001 2 commits
-
-
simonmar authored
(forced commit, the last one had the wrong message) Make RTS flags given on the command line override those from the GHCRTS environment variable.
-
simonmar authored
Move RtsFlags.h into ghc/includes, so it's available in a binary installation. RtsFlags.h was repository-copied behind the scenes to keep the revision history.
-