Commit Graph

41 Commits

Author SHA1 Message Date
kwasimensah
2f58cf0d00 Fix MACROS for when BT_THREADSAFE is defined 2017-11-12 00:48:59 -05:00
kwasimensah
8aefa7e8d0 Updating Macros
Don't take away ability to do profiling on MacOS
2017-11-03 11:59:12 -04:00
kwasimensah
e03383e612 Update support for buggy android NDK
Expand logic for when __thread is supported to work around https://github.com/android-ndk/ndk/issues/8
2017-11-02 15:35:59 -04:00
Lunkhound
0fc3ce69e9 fix thread index going out of range bug 2017-06-03 18:03:59 -07:00
Erwin Coumans
ee0e3ba271 Remove RobotLogging from CMakeLists.txt
Avoid crashing if threadIndex exceeds BT_QUICKPROF_MAX_THREAD_COUNT (64)
2017-03-23 18:00:00 -07:00
erwincoumans
ef9afd39f7 Merge pull request #996 from iSLC/master
Adjust thread-local local static variable syntax for MinGW/GCC.
2017-03-13 21:52:06 -07:00
Szabolcs Dombi
839086ac84 fix type conversion warnings 2017-03-13 18:30:44 +01:00
Sandu Liviu Catalin
bbb7e3c5f5 Adjust thread-local local static variable syntax for MinGW/GCC. 2017-03-08 00:46:39 +02:00
erwincoumans
e738d1ffde fix for iOS, add #include <TargetConditionals.h> 2017-01-13 12:06:13 -08:00
Erwin Coumans
5e6cfd70b5 iOS platform and Android don't have __thread local storage, so avoid multi-threaded profiler on those (only on _WIN32, __linux__ and __APPLE__ and not TARGET_OS_IPHONE
Add a Sleep(0) for Windows to yield threads (and not Sleep(1))
2017-01-08 12:49:04 -08:00
Erwin Coumans
a4cf0c8b11 Linux clock_gettime needs rt / librt, so put it behind BT_LINUX_REALTIME for now. 2016-12-26 22:00:39 -08:00
Erwin Coumans
7aa7c4dfee Linux needs #include <time.h>?
/home/travis/build/bulletphysics/bullet3/src/LinearMath/btQuickprof.cpp:251:19: error: ‘CLOCK_REALTIME’ was not declared in this scope
/home/travis/build/bulletphysics/bullet3/src/LinearMath/btQuickprof.cpp:251:37: error: ‘clock_gettime’ was not declared in this scope
2016-12-26 21:15:59 -08:00
Erwin Coumans
0917310521 add nanosecond resolution for Mac OSX clock / about://tracing timings 2016-12-23 18:18:35 -08:00
Erwin Coumans
4c06fd27b3 Example Browser: add option (keypress 'p') to dump json timing profile trace, that you can open using Chrome about://tracing
Make btQuickprof thread safe
Add option in btQuickprof to override custom timing profile (btSetCustomEnterProfileZoneFunc, btSetCustomLeaveProfileZoneFunc)
remove b3Printf in a user/physics thread (those added added, while drawing the GUI running in the main thread)
2016-12-23 15:20:04 -08:00
Lunkhound
1c3686ca51 MultiThreaded Demo:
- fixing various race conditions throughout (usage of static vars, etc)
 - addition of a few lightweight mutexes (which are compiled out by default)
 - slight code rearrangement in discreteDynamicsWorld to facilitate multithreading
 - PoolAllocator::allocate() can now be called when pool is full without
     crashing (null pointer returned)
 - PoolAllocator allocate and freeMemory, are OPTIONALLY threadsafe
     (default is un-threadsafe)
 - CollisionDispatcher no longer checks if the pool allocator is full
     before calling allocate(), instead it just calls allocate() and
     checks if the return is null -- this avoids a race condition
 - SequentialImpulseConstraintSolver OPTIONALLY uses different logic in
     getOrInitSolverBody() to avoid a race condition with kinematic bodies
 - addition of 2 classes which together allow simulation islands to be run
   in parallel:
    - btSimulationIslandManagerMt
    - btDiscreteDynamicsWorldMt
 - MultiThreadedDemo example in the example browser demonstrating use of
   OpenMP, Microsoft PPL, and Intel TBB
 - use multithreading for other demos
 - benchmark demo: add parallel raycasting
2016-10-30 12:47:27 -07:00
erwin coumans
25a1714754 disable CProfileManager, might reduce some multi-threading conflicts 2016-07-19 15:55:52 -07:00
erwincoumans
c293c3df8f Update btQuickprof.cpp 2015-07-08 23:22:41 -07:00
erwincoumans
4366070611 Update btQuickprof.cpp
deal with Windows XP users, see https://github.com/bulletphysics/bullet3/issues/289#issuecomment-119133169
2015-07-08 22:28:20 -07:00
erwincoumans
a159fbac69 Improved URDF support for btMultiBody and separate graphics/collision/inertial frames and shapes
Fix WinXP GetTickCount64 with a typedef
Expose debug drawing mode/flags in UI (hot keys A,D,L,W for now, buttons later)
GLInstancingRenderer: tweak near/far planes to allow closer approach of camera
btDiscreteDynamicsWorld: enable debug drawing for btGeneric6DofSpring2Constraint
btMultiBodyDynamicsWorld: enable basic debug drawing for btMultiBody
btMultibody: allow center-of-mass shift for prismatic and fixed constraint
2015-01-22 17:56:24 -08:00
erwin coumans
aaaf8dc4e2 Enable CMake support for Windows Phone (_WIN32+_M_ARM) and Windows Store Apps,
Use this recent cmake version (http://cmakems.codeplex.com/) or future cmake that has the Windows Phone/Store App support
Use the following defines in CMake:
-DCMAKE_SYSTEM_NAME=WindowsPhone or -DCMAKE_SYSTEM_NAME=WindowsStore
-DCMAKE_SYSTEM_VERSION=8.0 or -DCMAKE_SYSTEM_VERSION=8.1
Thanks to Microsoft OSS group for the patch!
2014-10-24 15:44:33 -07:00
Erwin Coumans
4af9c5a4c9 remove some warnings 2014-08-21 13:32:32 -07:00
Haydn Trigg
3d944782e9 Update btQuickprof.cpp
removed inline declaration from get time seconds function definition
2014-08-01 07:25:31 +09:30
Haydn Trigg
6ff7a6d48b Update btQuickprof.cpp 2014-07-26 00:44:16 +09:30
Erwin Coumans
8eb1835415 fix a potential bug in CProfileNode destructor, if the SDK is included/used multiple times. 2014-04-28 11:24:29 -07:00
erwincoumans
31998c8e7d minor issues (don't use \n in B3_PROFILE, and don't report timing inaccuracy in console 2014-01-29 15:25:36 -08:00
erwin.coumans
642a6821a5 remove speculative contacts, they break restitution and cause other artifacts
use btConvexPolyhedron for debug rendering, if available
fixes in btConvexConvexAlgorithm for polyhedral contact clipping, if GJK separating normal is zero
don't shift vertices in btPolyhedralConvexShape
2011-08-30 03:28:32 +00:00
erwin.coumans
318e0d74dc Fix in btQuickprof that caused crash in ConcaveConvexcastDemo.cpp
Thanks to Roman Ponomarev for the report
Make btVector3::rotate const
Thanks to lepoussin, see Issue 428
CMakeLists.txt improvement: don't copy resources when INTERNAL_CREATE_DISTRIBUTABLE_MSVC_PROJECTFILES is set
CMakeLists.txt improvement: INSTALL_EXTRA_LIBS for ConvexDecomposition and GIMPACTUtils
Thanks to andrebra, see Issue 425
2010-09-18 00:24:50 +00:00
erwin.coumans
32714313a8 Move btClock into .cpp file, similar to Issue 381 2010-08-24 23:43:00 +00:00
erwin.coumans
788f48643b remove all warnings on Mac OSX Snow Leopard 2010-01-30 22:31:56 +00:00
erwin.coumans
67133c403d remove the LinearMath/ prefix for includes within the LinearMath directory
Thenks tasioga for the patch, see http://code.google.com/p/bullet/issues/detail?id=333
2010-01-19 06:13:44 +00:00
erwin.coumans
5493ba8411 Updated ChangeLog
Rename CProfileManager::DumpAll to CProfileManager::dumpAll
2008-11-12 22:52:13 +00:00
erwin.coumans
5feea39803 Fix compilation for MSVC 6.0 for Bullet and COLLADA DOM.
Fix issues with btDbvt: use ATTRIBUTE_ALIGNED16
Removed several places where variable was declared within for statement: for (int i=0; should be int i; for (i=0
2008-11-12 18:37:05 +00:00
erwin.coumans
c4bd276dfc make it easier to disable btQuickProf,
added a CProfileManager::DumpAll, to dump/printf all timings for one simulation frame.
2008-11-12 02:45:59 +00:00
erwin.coumans
88ee734bfb added custom memory allocator registration, thanks to Sly.
call CProfileManager::CleanupMemory(), to cleanup btQuickprof memory.
changed include from #include <new.h> to #include <new> in btOdeQuickstepConstraintSolver.cpp
2008-05-24 06:10:09 +00:00
ejcoumans
d051e2eacb First commit of 2008, Happy New Year!
Add option to compile without btClock and without profiling: comment out USE_BT_CLOCK, and #define BT_NO_PROFILE
Fixed typo/case in #include "LinearMath/btQuickProf.h", in SpuParallelSolver.cpp
Removed unnecessary files from libxml CMakeLists.txt
2008-01-03 04:42:00 +00:00
ejcoumans
17a214a2b3 - Added btRigidBodyConstructionInfo, to make it easier to set individual setting (and leave other untouched) during rigid body construction.
This was harder using default arguments. Thanks Vangelis Kokkevis for pointing this out.
- Fixed memoryleak in the ConstraintDemo and Raytracer demo.
- fixed issue with clearing forces/gravity at the end of the stepSimulation, instead of during internalSingleStepSimulation.
Thanks chunky for pointing this out: http://www.bulletphysics.com/Bullet/phpBB3/viewtopic.php?f=9&t=1780
- Disabled additional damping in rigid body by default, but enable it in most demos. Set btRigidBodyConstructionInfo m_additionalDamping to true to enable this.
- Removed obsolete QUICKPROF BEGIN/END_PROFILE, and enabled BT_PROFILE. Profiling is enabled by default (see Bullet/Demos/OpenGL/DemoApplication.cpp how to use this).
User can switch off profiling by enabling define BT_NO_PROFILE in Bullet/src/btQuickprof.h.
2007-12-17 04:26:36 +00:00
ejcoumans
0da5790e5c small update on hierarchical timing integration 2007-11-21 03:49:23 +00:00
ejcoumans
cab75b53ec added hierarchical profiling (needs more cleanup)
avoid dynamic allocations in btRaycastVehicle
2007-11-21 03:00:40 +00:00
ejcoumans
151cd4b9da prepare and added constraint solver optimizations, not activated yet. 2007-03-17 00:09:12 +00:00
ejcoumans
a42718f753 quickprof (optional performance tuning) changed into Zlib license,entire Bullet/src folder is Zlib again. (thanks Tyler Streeter) 2006-11-09 18:44:28 +00:00
ejcoumans
eb23bb5c0c merged most of the changes from the branch into trunk, except for COLLADA, libxml and glut glitches.
Still need to verify to make sure no unwanted renaming is introduced.
2006-09-27 20:43:51 +00:00