bugGNU Octave - Bugs: bug #58271, [octave forge] (parallel) 4.0.0:...

 
 

bug #58271: [octave forge] (parallel) 4.0.0: classdef objects in arguments pose issues

Submitter:  A.R. Burgers <arb>
Submitted:  Wed 29 Apr 2020 07:57:59 AM UTC
   
 
Category:  Octave Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Regression
Status:  None Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * other Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Sat 02 May 2020 04:35:28 PM UTC, comment #1: 


> I think this is related to bug #45831. In the fork based
> approach the fork call takes care of the copying of data to the
> childeren, without need for serialization. In the new approach
> the data is serialized and sent to the children.
> For returning data from the children the fork based approach
> already used serialization.


This is correct.


Olaf Till <i7tiol>
Group Member
Wed 29 Apr 2020 07:57:59 AM UTC, original submission:  

Consider the following script. It will work with cellfun and fork based pre-4.0.0 parcellfun, but error with 4.0.0 parcellfun:


pkg load parallel;
pkg_ver = ver('parallel')
ver = version

ci = containers.Map({'a','b','c'}, {1,2,3});
cf_out = cellfun(@(x) ci(x)*2, ci.keys)
pcf_out = parcellfun(3, @(x) ci(x)*2, ci.keys)


pre - 4.0.0 output:

pkg_ver = scalar structure containing the fields:
    Name = parallel
    Version = 3.1.3
    Release = [](0x0)
    Date = 2018-08-03

ver = 5.2.1
cf_out =
   2   4   6

parcellfun: 3/3 jobs done
pcf_out =
   2   4   6


4.0.0 output:

pkg_ver = scalar structure containing the fields:
    Name = parallel
    Version = 4.0.0
    Release = [](0x0)
    Date = 2020-04-11

ver = 6.0.1
cf_out =
   2   4   6

error: octave_base_value::save_binary(): wrong type argument 'object'
error: clone: invalid object


I think this is related to bug #45831. In the fork based approach the fork call takes care of the copying of data to the childeren, without need for serialization. In the new approach the data is serialized and sent to the childeren.
For returning data from the childeren the fork based approach already used serialization.

If this assessment is correct, then this is not a bug in the parallel package, but rather a manifestation of the absence of serialization capability for classdef objects in octave.

A.R. Burgers <arb>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by jwe (Updated the item)
  • -email is unavailable- added by seijikun
  • -email is unavailable- added by siko1056 (Updated the item)
  • -email is unavailable- added by i7tiol (Posted a comment)
  • -email is unavailable- added by arb (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-11-27 jwe Release6.0.90 other
    2020-06-17 seijikun Carbon-Copy- Added seijikun
    2020-05-28 siko1056 Summary[octave-forge](parallel) 4.0.0: classdef objects in arguments pose issues [octave forge] (parallel) 4.0.0: classdef objects in arguments pose issues

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code