29936 Commits

Author SHA1 Message Date
Ingo Weinhold
6a1f462e72 * arch_debug_get_interrupt_pc() does now optionally return whether the iframe
is a syscall iframe.
* User debugger support: Don't to call BreakpointManager::PrepareToContinue(),
  if the thread returns from a syscall. We don't want to skip breakpoints in
  that case.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31223 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31223
2009-06-24 11:49:35 +00:00
Axel Dörfler
3836be3e80 * Reworked GetKey() after Marcus' suggestions. Thanks for the extra motivation
to work on this :-)
* Also made it return "false" if there was no mapping, which will prevent empty
  dead keys to be written now (ie. the output now looks exactly like our
  sources).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31222 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31222
2009-06-24 09:00:22 +00:00
Ingo Weinhold
194b3b719a * Moved all handling of threads from TeamDebugger into new class ThreadHandler.
* Added new job to get the initial state of a thread.
* Now we also get the states of new threads correctly.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31221 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31221
2009-06-24 01:46:38 +00:00
Ingo Weinhold
74558e1c42 Renamed the "Stop" button to "Debug" to avoid confusion.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31220 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31220
2009-06-24 00:25:21 +00:00
Ingo Weinhold
719f89b06e Fixed the application quit mechanism. Due to the two levels of asynchronous
message sending the main thread exit()ed before the team debugger could process
its quit message. We're no longer taking the detour via Debugger when quitting
a window. The team debugger just quits and synchronously notifies the
application, which in turn waits until all team debugger threads have gone.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31219 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31219
2009-06-24 00:16:22 +00:00
Ingo Weinhold
fef6a27d78 * Moved killing/resuming the team to DebuggerInterface::Close().
* Made the TeamDebugger safer for the case that the initialization failed early.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31218 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31218
2009-06-23 23:09:36 +00:00
Ingo Weinhold
e951f678c2 Moved message code where it belongs.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31217 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31217
2009-06-23 22:29:15 +00:00
Ingo Weinhold
57c3ecadb8 * Fixed warning.
* Fixed creation of settings file. The second creat() parameter specifies the
  permission, not the open mode.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31216 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31216
2009-06-23 22:11:45 +00:00
Clemens Zeidler
4b8f258bfe - Forgot to set a timeout in Wait.
- Fix build if TRACE is enabled.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31215 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31215
2009-06-23 21:08:40 +00:00
Ingo Weinhold
b0f12d64f4 Added transparent software breakpoint support for user debuggers:
* The bulk of the work -- i.e. juggling the software and hardware breakpoints,
  watchpoints, and memory reads/writes -- is done in the new class
  BreakpointManager.
* For the architectures a few capability macros have to be defined, one
  pointing to the software breakpoint instruction opcode. Done for x86.
* Some more simplifications in the user debugger code, made possible by the
  recently introduced debugger_changed_condition attribute.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31214 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31214
2009-06-23 21:03:57 +00:00
Rudolf Cornelissen
63e909772d added DDC/EDID widescreen detection for analog connected screens. Switched off the force widescreen option so autodetection is actually used. This should fix non-ws DVI connected screens displaying black screens or shutting off on non-native modes. Bumped version to 0.93.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31213 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31213
2009-06-23 20:52:30 +00:00
Stephan Aßmus
c454df7e29 This stuff is actually used on the build host platform as well...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31209 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31209
2009-06-23 14:05:01 +00:00
Stephan Aßmus
4922427769 Implement killing the debugged team on quitting a TeamDebugger, the obviuos
way... thanks Ingo! Seems to work just fine.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31204 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31204
2009-06-23 13:09:50 +00:00
Stephan Aßmus
b9563a6fd9 Added NOTE on how to handle QuitRequested in the application and why using
the base class version is fine for now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31202 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31202
2009-06-23 12:20:14 +00:00
Stephan Aßmus
04743aeb5f Filled up the quitting code path a bit. The TeamDebugger throws up an alert
asking what to do with the debugged team. Killing it is not yet implemented.
Then it notifies the application about the quit request. That in turn tears
down the TeamDebugger and if no other ones are left, it quits itself.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31201 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31201
2009-06-23 12:14:05 +00:00
Stephan Aßmus
73b8cef5e6 Sorry for messing in this code, but I was a bit helpless how to fix the GCC2
build in another way...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31200 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31200
2009-06-23 12:12:08 +00:00
Stephan Aßmus
b9bbf08852 Small cleanup
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31199 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31199
2009-06-23 11:05:16 +00:00
Stephan Aßmus
e5a5e5da5a * Use auto-size-limits on the window.
* Use insets around everything. The visual change are insets also around the
  source code view. Another option would be to put the source code view on the
  right/bottom, attaching the window border and using a B_DOCUMENT_WINDOW
  resize knob on the window border. The register view could also use the
  additional height of the buttons. However, I agree it's somehow more logical
  to have the register view on the right side. Maybe only because of
  convention... so it's possibly still up for debate.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31198 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31198
2009-06-23 11:04:38 +00:00
Stephan Aßmus
4aeb7a3cc2 * Made BTwoDimensionalLayout and BSplitLayout::GetInsets() const.
* Give access to BSplitLayout::SetInsets() and GetInsets() from BSplitView.
* Give access to BSplitView::SetInsets() from BSplitLayoutBuilder and
  LayoutBuilder.
* Some automatic white-space cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31197 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31197
2009-06-23 10:56:22 +00:00
Axel Dörfler
e27f201987 * Added ability to save a "styles" attribute for StyledEdit. This implements
ticket #4032.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31196 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31196
2009-06-23 10:27:58 +00:00
Axel Dörfler
30dcc55d0a * More or less rewrote main.cpp to use getopt_long() instead of the self-made
argument evaluation. Also separated the evaluation from performing the
  options, solving a TODO, and added long versions for the options.
* Changed Keymap methods to work on a path instead of entry_refs - this
  simplifies the code a bit over the place.
* Added new option to load a source keymap directly (-s, --load-source).
* Renamed some methods to make clearer what they do.
* Added a way to directly write a source keymap to a file (by specifying the
  -o option together with -d).
* Coding style cleanup, ordered Keymap methods in the order they are declared.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31195 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31195
2009-06-23 09:44:31 +00:00
Ingo Weinhold
ba391bcc56 Added team_debug_info::debugger_changed_condition to serialize changes to the
installed team debugger and adjusted the code accordingly. It's not needed yet,
but I intend to add support for software breakpoints and those require a bit of
uninitialization that needs to be synchronized with debugger changes and can't
be done with interrupts disabled.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31194 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31194
2009-06-23 01:39:51 +00:00
Ingo Weinhold
91393e7810 InterruptsSpinLocking:
* Removed unused inner struct State.
* Added work-around for the extremely annoying "fState my be used
  uninitialized" warning gcc 4 produces. I'm not aware of any solution that
  doesn't generate unnecessary code. :-/


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31193 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31193
2009-06-23 01:32:46 +00:00
Ingo Weinhold
6a6974b63e gcc 4 warnings.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31192 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31192
2009-06-23 01:29:47 +00:00
Ingo Weinhold
5ea5f51d84 Changed ConditionVariable from class to struct to make it more C-friendly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31191 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31191
2009-06-22 23:49:05 +00:00
Ingo Weinhold
6dcc2a7e00 Made destroy_team_debug_info() static, as it's not used outside the source
file.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31190 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31190
2009-06-22 23:46:55 +00:00
Ingo Weinhold
6381d6cc4e * Added Breakpoint class and extended TeamDebugModel to manage the objects.
Extended the event mechanism respectively.
* Added support to SourceView to display breakpoints and manipulate them.
* Extended TeamDebugger to install/uninstall breakpoints.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31189 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31189
2009-06-22 21:51:32 +00:00
Ingo Weinhold
7c439b2356 Added {Install,Uninstall}Breakpoint().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31188 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31188
2009-06-22 21:44:09 +00:00
Ingo Weinhold
e20dc8a7b7 Added missing convenience methods for unsigned integers.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31187 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31187
2009-06-22 21:43:06 +00:00
Ingo Weinhold
6cd189c997 Added BinarySearchIndex().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31186 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31186
2009-06-22 21:41:16 +00:00
Rudolf Cornelissen
4ae1f25b97 fixed typo in unused routine I think.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31185 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31185
2009-06-22 20:52:15 +00:00
Rudolf Cornelissen
8f9bd6355d removed leftover, this file was not used.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31184 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31184
2009-06-22 20:36:54 +00:00
Rudolf Cornelissen
8bdea4194a doing preparations for using analog widescreen detection. if all is right the driver's behaviour hasn't changed yet.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31183 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31183
2009-06-22 20:33:17 +00:00
Oliver Tappe
510c100a8f * synced wchar.h with POSIX and the implementations provided by our libroot
* added WCHAR_MIN and WCHAR_MAX - already as 32-bit values, since that's
  what wchar_t is going to become, soon (and those values could not have
  been used before, since they were missing)
* this is still work-in-progress though, I need to run more tests to find
  out which of these functions are actually working, too


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31182 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31182
2009-06-22 19:48:36 +00:00
Oliver Tappe
ebe1a956f0 * fixed a warning
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31181 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31181
2009-06-22 19:13:47 +00:00
Oliver Tappe
8ce2ca0fc7 * added a couple of wchar-related tests (from glibc-2.3.2) that expose
several problems in our wchar-support - the worst of which being that
  our compilers define wchar_t as short while the glibc-implementation
  is relying on it being 32-bits wide ...



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31180 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31180
2009-06-22 19:13:32 +00:00
Axel Dörfler
77fdfdfe5f * Fixed broken logic as pointed out by stippi.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31178 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31178
2009-06-22 11:26:15 +00:00
Axel Dörfler
c97f4931c8 * This should fix the app_server build under other architectures than x86.
* Fixed wrong operator precedence case in Painter::SetFont().
* Fixed dozens of style violations.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31177 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31177
2009-06-22 10:30:36 +00:00
Stephan Aßmus
448ab012ef Created an icon for the Debugger.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31176 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31176
2009-06-22 09:04:02 +00:00
Ingo Weinhold
ce5d942c1a Uninlined the implementations of the inner classes. No functional change.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31175 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31175
2009-06-22 01:30:55 +00:00
Ingo Weinhold
7367310fbe * Virtualized SourceCode and implemented a derived class DisassembledCode, which
allows to implement StatementAtAddress() in O(log(n).
* Added SourceCode::StatementAtLine().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31174 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31174
2009-06-22 01:13:57 +00:00
Ingo Weinhold
21821017e7 Added ContiguousStatement::AddressRange() for cheaper address range access.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31173 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31173
2009-06-22 01:09:26 +00:00
Ingo Weinhold
704e25ea2d Removed dead code.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31172 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31172
2009-06-22 01:08:44 +00:00
Ingo Weinhold
faa04e8d93 Also return the "commpage" image as one of the team's images.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31171 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31171
2009-06-22 00:07:13 +00:00
Ingo Weinhold
ede842bb1d * SourceView can now show markers for stack frame instruction pointers.
Furthermore it automatically scrolls to the current IP of the currently
  selected stack frame.
* TeamWindow:
  - Be lazy setting the SourceCode, i.e. as long as no other source shall be
    shown (e.g. another stack frame is selected) we keep the previous one.
  - When a new stack strace is set, automatically select the top-most frame.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31170 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31170
2009-06-21 23:44:18 +00:00
Ingo Weinhold
49ad0141cf Added StatementAtAddress() returning the statement at a given target address.
Needs optimization (iterates through all statements ATM).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31169 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31169
2009-06-21 23:30:18 +00:00
Ingo Weinhold
1df9bf1220 Added Statement::ContainsAddress().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31168 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31168
2009-06-21 23:28:13 +00:00
Ingo Weinhold
470c2c49a9 Passed incorrect instruction size to Statement constructor.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31167 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31167
2009-06-21 23:27:33 +00:00
Ingo Weinhold
e50cd9e51a Added Table::DeselectAllRows().
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31166 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31166
2009-06-21 23:26:53 +00:00
Stephan Aßmus
92772bbddd Patch by Christian Packmann:
* Implemented a CPU feature detection function in AppServer.cpp.
  The results are put into the global variable gAppServerSIMDFlags.
* Implemented an SIMD accelerated version of the bilinear bitmap
  scaling code that is the backend of BView::DrawBitmap(...,
  uint32 options) used by the MediaPlayer to smoothly upscale
  movies when no video overlay is available. The speed up is very
  noticable and a Core 2 Duo @ 1.8 GHz can play at 1920x1200 now
  without breaking a sweat. There is currently one SIMD version
  implemented which uses MMX and plain SSE.

Very cool! Thanks a lot!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31165 a95241bf-73f2-0310-859d-f6bbb57e9c96
hrev31165
2009-06-21 22:07:54 +00:00