Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » Question about EMFVM
Question about EMFVM [message #88760] Fri, 22 August 2008 13:13 Go to next message
Alfons Laarman is currently offline Alfons LaarmanFriend
Messages: 71
Registered: July 2009
Member
Hello all,

I noticed the the progression of the EMFVM implementation. Trying it myself
I run into some problems.
I get an ArrayOutOFBoundException(100) when executing my transformation. It
took me as a beginner ages to debug this to the point that i understood the
maximum stacksize was set to 100. Should i be able to create transformations
which don't prodduce such a high stack? In my project I do some imperative
post processing tasks, which involve iterating over produced model elements.
Here the stack size becomes more then 1000. I was not able to measure any
performance decrease from a larger stacksize, so why is it so small?

Which puzzles me a bit is the change in OCL. In some places OCL moves closer
to the OCL specification and in other places it moves away from it:
- Object.allInstancesFrom returns an Set now. OCL compliant, but not vm
compatible.
- String.split returns something which is not a Sequence. Or at least I
could not call last() nor asSequence() on it and had to do something like:
Sequence{x.split('!')}->flatten()->last()
- collection() flatten is recursive. I already noticed a comment in the
oldVM that the operation should be made recursive, however the way I
interpret the OCL spec it shouldn't be recursive. Still nicely inplemented
though ;)
Both cases it breaks conformance with ther old VM. So what is the policy, to
make the implementation more OCL compliant or to maintain compatibility with
the old VM?

Some other small things i noticed:
- Before I could reference MOF with "%EMF"!XXX, now it seems I have to load
the MOF metamodel separately.
- The syntax of toString on objects changed, I depend on it to find the
model an element is located in self.oclType().split('!')->first().


Thanks for your attention, Kind regards,

Alfons
Re: Question about EMFVM [message #88793 is a reply to message #88760] Fri, 22 August 2008 14:50 Go to previous messageGo to next message
Alfons Laarman is currently offline Alfons LaarmanFriend
Messages: 71
Registered: July 2009
Member
One other thing: String.toString puts quotes around the string. This can be
nasty when you want to use it in a polymorphic way.

Alfons

"Alfons Laarman" <a.w.laarman@student.utwente.nl> schreef in bericht
news:g8me1f$u96$1@build.eclipse.org...
> Hello all,
>
> I noticed the the progression of the EMFVM implementation. Trying it
> myself I run into some problems.
> I get an ArrayOutOFBoundException(100) when executing my transformation.
> It took me as a beginner ages to debug this to the point that i understood
> the maximum stacksize was set to 100. Should i be able to create
> transformations which don't prodduce such a high stack? In my project I do
> some imperative post processing tasks, which involve iterating over
> produced model elements. Here the stack size becomes more then 1000. I was
> not able to measure any performance decrease from a larger stacksize, so
> why is it so small?
>
> Which puzzles me a bit is the change in OCL. In some places OCL moves
> closer to the OCL specification and in other places it moves away from it:
> - Object.allInstancesFrom returns an Set now. OCL compliant, but not vm
> compatible.
> - String.split returns something which is not a Sequence. Or at least I
> could not call last() nor asSequence() on it and had to do something like:
> Sequence{x.split('!')}->flatten()->last()
> - collection() flatten is recursive. I already noticed a comment in the
> oldVM that the operation should be made recursive, however the way I
> interpret the OCL spec it shouldn't be recursive. Still nicely inplemented
> though ;)
> Both cases it breaks conformance with ther old VM. So what is the policy,
> to make the implementation more OCL compliant or to maintain compatibility
> with the old VM?
>
> Some other small things i noticed:
> - Before I could reference MOF with "%EMF"!XXX, now it seems I have to
> load the MOF metamodel separately.
> - The syntax of toString on objects changed, I depend on it to find the
> model an element is located in self.oclType().split('!')->first().
>
>
> Thanks for your attention, Kind regards,
>
> Alfons
>
Re: Question about EMFVM [message #88809 is a reply to message #88793] Fri, 22 August 2008 15:33 Go to previous messageGo to next message
Alfons Laarman is currently offline Alfons LaarmanFriend
Messages: 71
Registered: July 2009
Member
I continue, OrderedSet.indexOf is missing.

Alfons

"Alfons Laarman" <a.w.laarman@student.utwente.nl> schreef in bericht
news:g8mjob$6da$1@build.eclipse.org...
> One other thing: String.toString puts quotes around the string. This can
> be
> nasty when you want to use it in a polymorphic way.
>
> Alfons
>
> "Alfons Laarman" <a.w.laarman@student.utwente.nl> schreef in bericht
> news:g8me1f$u96$1@build.eclipse.org...
>> Hello all,
>>
>> I noticed the the progression of the EMFVM implementation. Trying it
>> myself I run into some problems.
>> I get an ArrayOutOFBoundException(100) when executing my transformation.
>> It took me as a beginner ages to debug this to the point that i
>> understood the maximum stacksize was set to 100. Should i be able to
>> create transformations which don't prodduce such a high stack? In my
>> project I do some imperative post processing tasks, which involve
>> iterating over produced model elements. Here the stack size becomes more
>> then 1000. I was not able to measure any performance decrease from a
>> larger stacksize, so why is it so small?
>>
>> Which puzzles me a bit is the change in OCL. In some places OCL moves
>> closer to the OCL specification and in other places it moves away from
>> it:
>> - Object.allInstancesFrom returns an Set now. OCL compliant, but not vm
>> compatible.
>> - String.split returns something which is not a Sequence. Or at least I
>> could not call last() nor asSequence() on it and had to do something
>> like: Sequence{x.split('!')}->flatten()->last()
>> - collection() flatten is recursive. I already noticed a comment in the
>> oldVM that the operation should be made recursive, however the way I
>> interpret the OCL spec it shouldn't be recursive. Still nicely
>> inplemented though ;)
>> Both cases it breaks conformance with ther old VM. So what is the policy,
>> to make the implementation more OCL compliant or to maintain
>> compatibility with the old VM?
>>
>> Some other small things i noticed:
>> - Before I could reference MOF with "%EMF"!XXX, now it seems I have to
>> load the MOF metamodel separately.
>> - The syntax of toString on objects changed, I depend on it to find the
>> model an element is located in self.oclType().split('!')->first().
>>
>>
>> Thanks for your attention, Kind regards,
>>
>> Alfons
>>
>
>
[ATL] Re: Question about EMFVM [message #89047 is a reply to message #88760] Tue, 26 August 2008 09:08 Go to previous message
William Piers is currently offline William PiersFriend
Messages: 301
Registered: July 2009
Senior Member
Hi Alfons,

Comments below :

Alfons Laarman a écrit :
> Hello all,
>
> I noticed the the progression of the EMFVM implementation. Trying it myself
> I run into some problems.
> I get an ArrayOutOFBoundException(100) when executing my transformation. It
> took me as a beginner ages to debug this to the point that i understood the
> maximum stacksize was set to 100. Should i be able to create transformations
> which don't prodduce such a high stack? In my project I do some imperative
> post processing tasks, which involve iterating over produced model elements.
> Here the stack size becomes more then 1000. I was not able to measure any
> performance decrease from a larger stacksize, so why is it so small?
>

It was a restriction in order to limit performance issues at this level
I think. But after reading the description of your needs I think that we
simply must allow to parametrize this value. Could you please add a
feature request on bugzilla for that question ? Thanks in advance.

> Which puzzles me a bit is the change in OCL. In some places OCL moves closer
> to the OCL specification and in other places it moves away from it:
> - Object.allInstancesFrom returns an Set now. OCL compliant, but not vm
> compatible.
> - String.split returns something which is not a Sequence. Or at least I
> could not call last() nor asSequence() on it and had to do something like:
> Sequence{x.split('!')}->flatten()->last()
> - collection() flatten is recursive. I already noticed a comment in the
> oldVM that the operation should be made recursive, however the way I
> interpret the OCL spec it shouldn't be recursive. Still nicely inplemented
> though ;)
> Both cases it breaks conformance with ther old VM. So what is the policy, to
> make the implementation more OCL compliant or to maintain compatibility with
> the old VM?

In fact the policy is more to maintain compatibility with the old VM.
But some ameliorations are allowed, like the recursive flatten: the goal
is to provide a simple language.
Anyway, for the split it seems to be a regression more than an
evolution, so you can report a bug.

>
> Some other small things i noticed:
> - Before I could reference MOF with "%EMF"!XXX, now it seems I have to load
> the MOF metamodel separately.
> - The syntax of toString on objects changed, I depend on it to find the
> model an element is located in self.oclType().split('!')->first().
>
>
> Thanks for your attention, Kind regards,
>
> Alfons
>
>

You can report a bug for each of these problem. But I know it is not
costless, and you ever reported them here so I will keep an eye on this
subject, and report important bugs myself if necessary.

Anyway, thank you for reporting those problems!

Best regards,

William
Previous Topic:helper produces execution error:java.lang.RuntimeException.Can you help me,pleas
Next Topic:Can I do a helper that return a enumeration?
Goto Forum:
  


Current Time: Thu Apr 25 01:57:12 GMT 2024

Powered by FUDForum. Page generated in 0.03169 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top