Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r52480 - in sandbox/memory/boost/memory: . future stl
From: xushiweizh_at_[hidden]
Date: 2009-04-19 05:09:41


Author: xushiwei
Date: 2009-04-19 05:09:40 EDT (Sun, 19 Apr 2009)
New Revision: 52480
URL: http://svn.boost.org/trac/boost/changeset/52480

Log:
remove all components about:
1. gc_alloc
2. lock free
Removed:
   sandbox/memory/boost/memory/future/
   sandbox/memory/boost/memory/stl/
Text files modified:
   sandbox/memory/boost/memory/scoped_alloc.hpp | 82 ++++-----------------------------------
   1 files changed, 9 insertions(+), 73 deletions(-)

Modified: sandbox/memory/boost/memory/scoped_alloc.hpp
==============================================================================
--- sandbox/memory/boost/memory/scoped_alloc.hpp (original)
+++ sandbox/memory/boost/memory/scoped_alloc.hpp 2009-04-19 05:09:40 EDT (Sun, 19 Apr 2009)
@@ -160,9 +160,17 @@
         
 public:
         tls_block_pool_() {
- _tls_blockPool->init();
+ init();
         }
         ~tls_block_pool_() {
+ term();
+ }
+
+ static void BOOST_MEMORY_CALL init() {
+ _tls_blockPool->init();
+ }
+
+ static void BOOST_MEMORY_CALL term() {
                 _tls_blockPool->term();
         }
 
@@ -194,80 +202,8 @@
 // -------------------------------------------------------------------------
 // class scoped_alloc
 
-#if 0 // defined(_MSC_VER) && (_MSC_VER <= 1200) // VC++ 6.0
-
-class scoped_alloc
-{
-private:
- region_alloc<NS_BOOST_MEMORY_POLICY::pool> m_impl;
-
-public:
- scoped_alloc() {}
- explicit scoped_alloc(scoped_alloc&) {}
-
- __forceinline void BOOST_MEMORY_CALL swap(scoped_alloc& o) {
- m_impl.swap(o.m_impl);
- }
-
- __forceinline void BOOST_MEMORY_CALL clear() {
- m_impl.clear();
- }
-
- __forceinline void* BOOST_MEMORY_CALL allocate(size_t cb) {
- return m_impl.allocate(cb);
- }
-
-#if defined(BOOST_MEMORY_NO_STRICT_EXCEPTION_SEMANTICS)
- __forceinline void* BOOST_MEMORY_CALL allocate(size_t cb, int fnZero) {
- return m_impl.allocate(cb);
- }
-
- __forceinline void* BOOST_MEMORY_CALL allocate(size_t cb, destructor_t fn) {
- return m_impl.allocate(cb, fn);
- }
-#endif
-
- __forceinline void* BOOST_MEMORY_CALL unmanaged_alloc(size_t cb, destructor_t fn) {
- return m_impl.unmanaged_alloc(cb, fn);
- }
-
- __forceinline void BOOST_MEMORY_CALL manage(void* p, destructor_t fn) {
- m_impl.manage(p, fn);
- }
-
- __forceinline void* BOOST_MEMORY_CALL unmanaged_alloc(size_t cb, int fnZero) {
- return m_impl.allocate(cb);
- }
-
- __forceinline void BOOST_MEMORY_CALL manage(void* p, int fnZero) {
- // no action
- }
-
- void* BOOST_MEMORY_CALL reallocate(void* p, size_t oldSize, size_t newSize) {
- return m_impl.reallocate(p, oldSize, newSize);
- }
-
- void BOOST_MEMORY_CALL deallocate(void* p, size_t cb) {
- // no action
- }
-
- template <class Type>
- void BOOST_MEMORY_CALL destroy(Type* obj) {
- // no action
- }
-
- template <class Type>
- void BOOST_MEMORY_CALL destroyArray(Type* array, size_t count) {
- // no action
- }
-};
-
-#else
-
 typedef region_alloc<NS_BOOST_MEMORY_POLICY::pool> scoped_alloc;
 
-#endif
-
 // -------------------------------------------------------------------------
 // $Log: $
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk