Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-05-01 Thread Maciej Izak
2018-04-30 21:30 GMT+02:00 Michael Van Canneyt : > I can imagine that checking such a field will be more fast than actually >>> calling a routine. This is just a thought, if you had already considered >>> such a thing, I would like to hear why you discarded it, for my >>> education. >>> >> >> >> t

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Michael Van Canneyt
On Mon, 30 Apr 2018, Anthony Walter wrote: Okay, I found a nice work around to allow for circular references on record types: record helpers type JSValue = record ... end; JSObject = record ... end; JSValueHelper = record helper for JSValue function AsObject: JSObject; end; JS

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Anthony Walter
Okay, I found a nice work around to allow for circular references on record types: record helpers type JSValue = record ... end; JSObject = record ... end; JSValueHelper = record helper for JSValue function AsObject: JSObject; end; JSObjectHelper= record helper for JSObje

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Anthony Walter
Thanks for replying. I'd like to chime in with a few thoughts.. I believe manged types beyond string, dynamic array, and interface as important. In my use case worked around the problem by using records with private interface as I already mentioned. This solution is less than optimal as it require

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Michael Van Canneyt
On Mon, 30 Apr 2018, Maciej Izak wrote: I can imagine that checking such a field will be more fast than actually calling a routine. This is just a thought, if you had already considered such a thing, I would like to hear why you discarded it, for my education. this is exactly what is done i

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Maciej Izak
2018-04-30 20:56 GMT+02:00 Michael Van Canneyt : > There is no agression. There is critique. > > Maybe the others were satisfied with your solution I am not. So I brought > it > again to everyone's attention. There is difference between rudeness and critique. You are just rude, for someone from

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Michael Van Canneyt
On Mon, 30 Apr 2018, Maciej Izak wrote: 2018-04-30 14:59 GMT+02:00 Michael Van Canneyt : Maybe because your solution is simply not convincing and I wish to try and find a solution just a little harder ? Allow me to exaggerate the point a little: A bunch of changes are introduced, things ar

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Maciej Izak
2018-04-30 14:59 GMT+02:00 Michael Van Canneyt : > > Maybe because your solution is simply not convincing and I wish to try and > find a solution just a little harder ? > > Allow me to exaggerate the point a little: > > A bunch of changes are introduced, things are rammed through our throat > which

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Maciej Izak
2018-04-30 15:05 GMT+02:00 Mattias Gaertner : > Does that mean fpc 3.0.x had an unneeded overhead for classes without > managed types and 3.1 fixes this? > No, small unneeded overhead exist in both. The situation is different when managed types are used. FPC has similar solution for RTTI like De

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Mattias Gaertner
On Mon, 30 Apr 2018 14:43:02 +0200 Maciej Izak wrote: >[...] > With FastRTTI additional call to int_initialize is omitted when > possible. Furthermore > with FastRTTI all code is executed faster (much faster than in 3.0.x) > because all info about managed fields (for classes, objects and records)

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Michael Van Canneyt
On Mon, 30 Apr 2018, Maciej Izak wrote: 2018-04-30 13:53 GMT+02:00 Michael Van Canneyt : You mean that a constructor call for a program that does not uses pointers/management operators also gets slower ? Can we solve this _without_ additional tricks ? Because the fact that a feature you do

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Maciej Izak
2018-04-30 13:53 GMT+02:00 Michael Van Canneyt : > > You mean that a constructor call for a program that does not uses > pointers/management operators also gets slower ? > > Can we solve this _without_ additional tricks ? > > Because the fact that a feature you do not use slows down your code is no

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Michael Van Canneyt
On Mon, 30 Apr 2018, Maciej Izak wrote: 2018-04-30 13:15 GMT+02:00 Anthony Walter : Okay great. Thanks for the information. I'll experiment with the smart pointers and their potential performance impact. In the interim I've created a solution using the approach of records containing private

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Maciej Izak
2018-04-30 13:15 GMT+02:00 Anthony Walter : > Okay great. Thanks for the information. I'll experiment with the smart > pointers and their potential performance impact. In the interim I've > created a solution using the approach of records containing private > reference counted interfaces. Here is

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Anthony Walter
Okay great. Thanks for the information. I'll experiment with the smart pointers and their potential performance impact. In the interim I've created a solution using the approach of records containing private reference counted interfaces. Here is an example of my JSContext record: 1. JSContex

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-30 Thread Maciej Izak
2018-04-29 21:26 GMT+02:00 Anthony Walter : > I wanted to know from the people who make decision about what to merge, > what's the status of rolling his enhancements at following location into > FPC trunk? > The key part of smart pointers (management operators) is already in trunk (as Sven said).

Re: [fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-29 Thread Sven Barth via fpc-devel
Anthony Walter schrieb am So., 29. Apr. 2018, 21:27: > I've run into an almost must have use case for FPC smart pointers as > described and implemented by Maciej. I wanted to know from the people who > make decision about what to merge, what's the status of rolling his > enhancements at following

[fpc-devel] What's the status of Maciej's Smart Pointer enhancements?

2018-04-29 Thread Anthony Walter
Here is a video overview of this message I've run into an almost must have use case for FPC smart pointers as described and implemented by Maciej. I wanted to know from the people who make decision about what to merge, what's the status of ro