BrokenArrow Posted March 19, 2009 Report Share Posted March 19, 2009 I am wondering what the impact is of having constants, controls, and indicators inside or outside the loop of a fast Action Engine. It doesn't seem to matter in my testing (memory, speed). Quote Link to comment
Grampa_of_Oliva_n_Eden Posted March 19, 2009 Report Share Posted March 19, 2009 QUOTE (BrokenArrow @ Mar 18 2009, 08:29 AM) I am wondering what the impact is of having constants, controls, and indicators inside or outside the loop of a fast Action Engine. It doesn't seem to matter in my testing (memory, speed). See http://forums.ni.com/ni/board/message?board.id=170&view=by_date_ascending&message.id=191864#M191864' target="_blank">reply #12 in this thread on the dark-side where Greg McKaskle explained why the VI Analyzer want controls and indicators that are on the icon connector to be on the "root" of the diagram. Ben Quote Link to comment
BrokenArrow Posted March 19, 2009 Author Report Share Posted March 19, 2009 QUOTE (neBulus @ Mar 18 2009, 09:33 AM) See http://forums.ni.com/ni/board/message?board.id=170&view=by_date_ascending&message.id=191864#M191864' target="_blank">reply #12 in this thread on the dark-side where Greg McKaskle explained why the VI Analyzer want controls and indicators that are on the icon connector to be on the "root" of the diagram.Ben I read that post a while back and was wondering where it was - it was on my mind this week, thanks for finding it. "The caller has to protect the data on its wire from the subVI"... that kind of stuff blows my biscuit. Quote Link to comment
bsvingen Posted March 19, 2009 Report Share Posted March 19, 2009 This seems to be an ideal that has little significance for action engines. An action engine make use of shift registers to store data and/or states, and if you wire from the outside and on to the register, you accomplish nothing because you (re)initialize the shift register for each call. If you use the action engine to read and buffer data from some source, you will have to bypass the left shift register somehow during read, no matter what. I don't see how doing this inside the loop will be any worse than outside the loop. When there is no data to send to the AE, the worst thing that can happen is a copy of an empty array. When sending data from the AE, this can be done "on the other side" of the shift register. The rest of the input end of the action engine usually is some low byte count initializing stuff anyway (references etc). I mean, the data going into the AE may not even be of the same format or type as the data going out of the AE. If you have to pass huge amounts of other data through the AE, this is completely different, but why would you want to do that? But then again, my understanding of buffers is fuzzy at best Quote Link to comment
BrokenArrow Posted March 19, 2009 Author Report Share Posted March 19, 2009 QUOTE (bsvingen @ Mar 18 2009, 05:53 PM) .... and if you wire from the outside and on to the register, you accomplish nothing because you (re)initialize the shift register for each call. It's just simply not an AE if you do that! Quote Link to comment
bsvingen Posted March 20, 2009 Report Share Posted March 20, 2009 QUOTE (BrokenArrow @ Mar 18 2009, 11:30 PM) It's just simply not an AE if you do that! Exactly, so the reasons for placing controls outside of the while loop is simply not there for AE, unless you also pass through some additional large datasets. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.