hawq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From entong <...@git.apache.org>
Subject [GitHub] incubator-hawq pull request: HAWQ-246. Refactor and cleanup of mem...
Date Thu, 10 Dec 2015 23:27:12 GMT
GitHub user entong opened a pull request:

    https://github.com/apache/incubator-hawq/pull/181

    HAWQ-246. Refactor and cleanup of memory management of the new optimi…

    …zer.
    
    This commit eliminates the global new/delete overrides that were causing
    compatibility problems (the Allocators.(h/cpp/inl) files have been
    completely removed). The GPOS `New()` macro is retained and works the
    same way, but has been renamed `GPOS_NEW()` to avoid confusion and
    possible name collisions. `GPOS_NEW()` works only for allocating
    singleton objects. For allocating arrays, `GPOS_NEW_ARRAY()` is
    provided. Because we no longer override the global delete,
    objects/arrays allocated by `GPOS_NEW()` and `GPOS_NEW_ARRAY()` must now
    be deleted by the new functions `GPOS_DELETE()` and
    `GPOS_DELETE_ARRAY()` respectively. All code in GPOS has been
    retrofitted for these changes, but Orca and other code that depends on
    GPOS should also be changed.
    
    Note that `GPOS_NEW()` and `GPOS_NEW_ARRAY()` should both be
    exception-safe and not leak memory when a constructor throws.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/entong/incubator-hawq gpos_new_delete

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/incubator-hawq/pull/181.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #181
    
----
commit acd3b79fbeb4529b7ca796a09cf44ac66bfa02a1
Author: Entong Shen <eshen@pivotal.io>
Date:   2015-12-10T06:02:52Z

    HAWQ-246. Refactor and cleanup of memory management of the new optimizer.
    
    This commit eliminates the global new/delete overrides that were causing
    compatibility problems (the Allocators.(h/cpp/inl) files have been
    completely removed). The GPOS `New()` macro is retained and works the
    same way, but has been renamed `GPOS_NEW()` to avoid confusion and
    possible name collisions. `GPOS_NEW()` works only for allocating
    singleton objects. For allocating arrays, `GPOS_NEW_ARRAY()` is
    provided. Because we no longer override the global delete,
    objects/arrays allocated by `GPOS_NEW()` and `GPOS_NEW_ARRAY()` must now
    be deleted by the new functions `GPOS_DELETE()` and
    `GPOS_DELETE_ARRAY()` respectively. All code in GPOS has been
    retrofitted for these changes, but Orca and other code that depends on
    GPOS should also be changed.
    
    Note that `GPOS_NEW()` and `GPOS_NEW_ARRAY()` should both be
    exception-safe and not leak memory when a constructor throws.

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message