Commit Graph

26091 Commits

Author SHA1 Message Date
Stefano Ceccherini c8ffdabb35 Fixed memcpy in case a smaller function table is provided. Improved readability of the SET_CLIPPING_RECT op block.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27315 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-04 08:22:00 +00:00
Ingo Weinhold 537d081817 release_sem_etc(): Reschedule only when a thread with a priority greater
than that of the current thread has been woken up. I didn't see the
reason why the thread should otherwise relinquish the rest of its
quantum. I noticed for instance that client and app server window
threads were ping-ponging more than seemed necessary. In most cases
when the client sent a port message it would be unscheduled although it
had run only for a few microseconds and had still stuff to do.
I measured a relatively Terminal-heavy "find /boot" (second run), which
does now take 5-10% less time.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27314 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-04 00:32:12 +00:00
Ingo Weinhold f88e298ec7 * In the timing table user and kernel time were swapped.
* Scheduling analysis output:
  - Sort the threads by total run time.
  - Group the locking primitives a thread has waited on by common type
    and name. E.g. all "I/O request finished" condition variables are
    put in a single group. The sum wait time and wait count is printed
    for the group, so it is easy to see how often and how long the
    thread had waited for I/O.
  - Both the groups and their elements are sorted by wait time.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27313 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-04 00:13:53 +00:00
Ingo Weinhold e032a7f50e Scheduling analysis: Also record the number of times a thread waits on a
locking primitive.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27312 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-04 00:07:11 +00:00
Jérôme Duval 212426b00e fix warnings
white space cleanup


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27311 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 20:58:19 +00:00
Jérôme Duval 56ff2527e9 * on freeing, only remove the device when it is removed
* check if the device is still opened when waiting for data


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27310 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 19:18:42 +00:00
Jérôme Duval 1ccc2f2d7b fix debug build
on Stop(), close the device, then wait for our service thread to quit


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27309 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 19:14:37 +00:00
Jérôme Duval c08e99ef40 print errors when starting devices
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27308 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 19:12:18 +00:00
Jérôme Duval 04e088c3a9 I forgot that m68k build doesn't include long double versions of functions
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27307 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 18:59:12 +00:00
Ingo Weinhold 49de5a2f65 * Added "-s" option, which uses the new scheduling analysis feature to
gather additional information on the threads that were running and
  what they were doing.
* Added "-o <output>" option for specifying a file to which to print the
  statistics to.
* Some beautifications (usage, help, etc.).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27306 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 15:15:19 +00:00
Ingo Weinhold 886c05d0b6 Macro for additional scheduling analysis tracing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27305 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 15:11:41 +00:00
Ingo Weinhold 020ac56840 * Fixed bug in the "scheduler" command: The check when a thread was
unscheduled was incorrect.
* Introduced _kern_analyze_scheduling() syscall. It requires scheduler
  kernel tracing to be enabled. It uses the tracing entries for a given
  period of time to do a similar analysis the "scheduler" debugger
  command does (i.e. number of runs, run time, latencies, preemption
  times) for each thread. Additionally the analysis includes for each
  thread how long the thread waited on each locking primitive in total.
* Added kernel tracing for the creation of semaphores and initialization
  of condition variables, mutexes, and rw locks. The enabling macro is
  SCHEDULING_ANALYSIS_TRACING. The only purpose is to provide
  _kern_analyze_scheduling() with more info on the locking primitives
  (the name in particular).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27304 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 15:10:44 +00:00
Ingo Weinhold d5488b7703 Added ConditionVariable::ObjectType() getter.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27303 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 14:53:01 +00:00
Ingo Weinhold aa1a64f35a Added [un]lock_tracing_buffer(). This allows other components to analyze
tracing buffer entries even when not in the kernel debugger.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27302 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 14:51:00 +00:00
Ingo Weinhold 232fd3bae3 Moved the wait type definitions to <thread_defs.h>. We're going to use
them in userland, too.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27301 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 14:48:47 +00:00
Ingo Weinhold dd1c278d4b Added elf_get_image_info_for_address() to get an image info for a kernel
image.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27300 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 14:47:26 +00:00
Stephan Aßmus 5379de87bf Another attempt at improving the AboutSystem credits:
* The "Most influential developers" list wasn't such a good idea after all.
* Now we have "Current Maintainers" and "Past Maintainers". Some developers
  who still have commit access are in the Past Maintainers list, since they
  have not done a commit in a long time (more than a year at least)
* TODO: Move more people from Contributors into Past Maintainers, I don't
  know many names and have not tried to match names to SVN commit log nick
  names.
* Added Ralf Schuelke to the Contributors for his Pairs game contribution.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27299 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 13:40:56 +00:00
Karsten Heimrich c9503698ae * take the precision into account while trying to add an optional character
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27298 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 12:53:01 +00:00
Stefano Ceccherini 9fb13d5822 the virtual version is const
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27297 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 11:23:15 +00:00
Stefano Ceccherini 6e7954eb07 fixed warnings (gcc4). Style fixes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27296 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 10:01:58 +00:00
Salvatore Benedetto 25d466ba72 * Start implementing _kern_xsi_msgsnd().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27295 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 09:00:27 +00:00
Karsten Heimrich 84d0e984f3 * of by one, while left points behind the chars to copy
right points to the first charater to start copy with



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27294 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 02:15:30 +00:00
Ingo Weinhold b0b6878c97 <sys/ioctl.h> also seems to be the standard Linux place for the
ioctl() prototype. Apparently some Linuxes discarded the <stropts.h>
header which POSIX demands.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27293 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 00:39:45 +00:00
Karsten Heimrich 9bee8e939b * use the new get function
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27292 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 00:33:41 +00:00
Karsten Heimrich 9b56aad8a0 * rewrote truncate_middle partly, it failed while trying to add an optional character
this was most noticable in Deskbar when opening DataTranslations in Expand App Mode



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27291 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-03 00:26:25 +00:00
Ithamar R. Adema ed64c85f06 Attansic L2 Fast Ethernet driver for Haiku. Port of FreeBSD driver from:
http://www.SpringDaemons.com/stas/if_ae-1214569185.tar.bz2
(This is the wired NIC on the Asus EEE PC!)
NOTE: It is not in the image because it currently still crashes, will look into that soon.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27290 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 22:19:45 +00:00
Marcus Overhagen 1b65b57dd5 Fix tracing and improve memory usage. Thanks to Ingo for his hints.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27289 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 20:04:27 +00:00
Michael Pfeiffer 361a3434b4 * Delete longClickMessageRunner in destructor to avoid potential memory leak.
* Delete longClickMessageRunner after its message arrived, to shorten its lifetime.
* Moved creation and deletion of longClickMessageRunner into methods.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27288 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 16:40:22 +00:00
Stephan Aßmus 3f524cfc8d Rewrote ChannelControl.h
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27287 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 11:28:32 +00:00
Stephan Aßmus f3da4728e6 Listed classes that need tests yet.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27286 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 11:06:40 +00:00
Alexandre Deckner 4a89dc95cb - Don't leak the message given to BMessageRunner, thanks stippi!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27285 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 11:02:29 +00:00
Stephan Aßmus 86dab989e5 Added test for adding a BMenu instead of a BMenuItem, but everything works
fine, at least in the context of the layout management. I am investigating
a bug though that shows at least in WonderBrush (missing Filter menu).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27284 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 10:56:14 +00:00
Alexandre Deckner 57b269650e - Well, i told ya it was better with a BMessageRunner ;-P
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27283 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-02 02:20:12 +00:00
Marcus Overhagen 935ebe7840 Use kernel tracing feature. Doesn't seem to work, don't know why.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27282 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 21:26:46 +00:00
Marcus Overhagen 24bc53c351 ATA kernel tracing functions.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27281 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 21:25:44 +00:00
Stephan Aßmus af6342b8c7 Removed Jorge again by his own request. I completely forgot why Jorge was not
in the list and thought it was an oversight. Sorry.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27280 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 20:42:32 +00:00
Stephan Aßmus 737fa69d59 Sorry, but another fix was needed. The previous list of most influential
developers was based on the oloh results, but these go only 3 years back. The
SVN revision history is much more complete and contains also the CVS history
apart from a screw up at revision 10. However, I was able to obtain a much
more correct list now and so some resorting was due. According to these stats,
Michael Lotz would not appear in the list - however, I feel he should be
in there, since he was the first to run Haiku with app_server, the first to
run a browser on it, wrote the USB stack and so on. The other possiblity would
be to make the cut at 7 entries, which coincidentally would mean everyone in the
list has contributed more than 1000 commits.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27279 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 20:27:33 +00:00
Jérôme Duval 27c3792d1e added random_r.c
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27278 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 20:26:40 +00:00
Jérôme Duval 59e23729f5 added towctrans
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27277 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 20:18:49 +00:00
Rene Gollent 9442a1bb44 Just noticed this file was using CR/LF newlines...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27276 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 20:12:13 +00:00
Jérôme Duval 8a34e3d4de added getwchar and iofgetws
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27275 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 20:05:35 +00:00
Jérôme Duval 0ac2fa30a5 added gammal_r and lgammal_r private functions
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27274 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 19:54:55 +00:00
Marcus Overhagen 5b3feb866e Preparing support for ATA and ATAPI tracing
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27273 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 19:44:27 +00:00
Jérôme Duval 9c91170f95 added fpclassifyl
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27272 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 19:37:23 +00:00
Rene Gollent 7fb33cd07d I hate to add another special case, but with the way the BMenu* classes are designed, I see little in the way of alternatives. If we're a BMenuField's menu bar, then we should invoke the menu item regardless of where in the bar we click. This problem was visible in ticket #1877, where basically you could click only on the portion with text, because that was the size of the menu item, where the rest of the contained menu bar was considered dead space. Thus we now check if we're an instance of BMenuField's special menubar class, and if so we unconditionally select the item instead of a hit test. Fixes the aforementioned bug. If someone has a better approach, I'm all ears.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27271 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 19:33:50 +00:00
Jérôme Duval dd114a0c3f space cleanup
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27270 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 18:37:13 +00:00
Michael Pfeiffer da88cf3113 Added menu item "Show Calendar ..." to time pop up menu.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27269 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 17:50:06 +00:00
Salvatore Benedetto dc0cdfb2f0 * Fix a potential race condition when deleting a semaphore set: previously only
the ipc hash table lock along with the semaphore set hash table lock were
  hold, thinking (wrongly) that the semaphore set lock itself was not needed.
  What could happen was that another process on semop could have gained the lock
  of the set itself, and then release the semaphore set hash table lock.
  This would make it think that the set was still valid, while it could have
  actually been deleted right after it release the semaphore set hash table lock.
  Same would have happened for any other processes waiting on the semaphore set
  mutex queue. By calling the lock on the mutex when deleting the set, it
  *should be* safe to assume that there is no one else waiting on its queue,
  since the list of waiters is handled in a FIFO way.

As far as I can see from the mutex_destroy code, it looks safe to hold the lock
when calling this function. Please confirm.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27268 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 16:16:03 +00:00
Stefano Ceccherini 52b877461d Apply the same logic of r24682 to the drawing of BPictures inside BPictures. Fixes part of bug #1389 (drawing pictures at an offset). Thanks to Karsten for his observations!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27267 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 14:43:25 +00:00
Karsten Heimrich 014016620f * Month and Day should be used from the passed date
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27266 a95241bf-73f2-0310-859d-f6bbb57e9c96
2008-09-01 13:16:14 +00:00