From commits-return-58578-archive-asf-public=cust-asf.ponee.io@mxnet.incubator.apache.org Fri Oct 19 11:10:34 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 90482180674 for ; Fri, 19 Oct 2018 11:10:34 +0200 (CEST) Received: (qmail 59924 invoked by uid 500); 19 Oct 2018 09:10:33 -0000 Mailing-List: contact commits-help@mxnet.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@mxnet.incubator.apache.org Delivered-To: mailing list commits@mxnet.incubator.apache.org Received: (qmail 59915 invoked by uid 99); 19 Oct 2018 09:10:33 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 19 Oct 2018 09:10:33 +0000 From: GitBox To: commits@mxnet.apache.org Subject: [GitHub] squidszyd opened a new issue #12876: Crashes when calling `MXPredFree(handle)` Message-ID: <153994023304.22508.3701611198808906756.gitbox@gitbox.apache.org> Date: Fri, 19 Oct 2018 09:10:33 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit squidszyd opened a new issue #12876: Crashes when calling `MXPredFree(handle)` URL: https://github.com/apache/incubator-mxnet/issues/12876 I encounter `Segmentation Fault` issue when I call `MXPredFree` api to release prediction handler. Inside my program, there are two threads. The data thread loads data into buffer and the main thread looks for available data(batch size = B) in that buffer and select corresponding handler (initialized with batch size B) to do prediction. Note that when I call `MXPredForward`, there is a lock that ensure only one thread is calling it. (As far as I know, `MXPred` api is not thread-safe) When I stop the program, the main thread starts to loop through every handler and call `MXPredFree` to release them. However, there are chances (not every time) that my program crashes. I find that the crash happens at deconstruction of `vector` when the API calls `delete static_cast(handle)`. So, under what condition could this happen? Hope someone can help me with this. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services