Commit Graph

420 Commits

Author SHA1 Message Date
matrevis 6a1e30b0a2 - Reconstructed step forward. There is still some visible bug in the
imlpementation, so this version should not be considered definitive.
please give me an other day to check it.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@840 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-10 23:39:13 +00:00
elvez 17ca8156d9 - Completed policy-related error handling code
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@839 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-10 22:59:00 +00:00
elvez 48fc2f5a00 - Added still more error checking to PythonCPUPolicy. But the code which calls its methods should be updated to handle the new exceptions...
- Added a base class for cpu policy exceptions to make simpler their catching
- Implemented all numeric fields in dialogs with spinboxes, with bounds checking

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@838 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-10 00:42:17 +00:00
tchernobog d3c7b46853 - Give code a round of indentation. Thank astyle, not me.
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@837 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-09 14:38:45 +00:00
tchernobog aaf8e068d3 - Add prompt display for my mental sanity sake, so I know when I can type something
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@836 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-09 14:13:41 +00:00
tchernobog e975bfdd0b - Bugfix to call History::notify_change when reenabling notifications
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@830 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-08 19:46:14 +00:00
elvez 0138387a7f - Added the LOAD command to TextSimulation, and the classic question made to user on replacing an unsaved simulation
- Changed the way syntactically incorrect python policies are handled, we no more exit abruptly

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@829 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-08 00:20:56 +00:00
matrevis d72ce96508 - Corrected a bug in step forward, which was incorrectly assuming
that the size of the history was the coordinate of the instant
  to add.
- Corrected a bug in step forward, which was incorrectly assuming
  that all processes started at instant 0.
- Added a wizard to show a bug in step forward, which thinks that
  the simulation is terminated while it isn't since some processes
  are still future.
- Commented some unused code in step forward (extendThread()).
- Still to extract methods from Extender and provide them to 
  step forward in a more suitable (static) way.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@828 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-07 23:59:21 +00:00
tchernobog a7fc644043 - Fix compilation and loading of XmlSave plugin
- Fix throwing of exceptions from sgpem::Module
- **THOU SHALL ALWAYS UPDATE THY MAKEFILES, OR THE WRATH OF GOD
WILL DESCEND UPON THEE**


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@827 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-07 15:16:27 +00:00
elvez 96728edfce - Fixed compilation errors caused by latest changes to serialization code
- Setup makefile for xmlsave plugin. It still can`t be activated. why?
- Added a temporary command SAVE to commandline interface to try serialization

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@826 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-07 00:54:43 +00:00
matrevis 574723a35b - Added full request support, altough still not working
at all. Compiles and runs, but the output is not
  correct. Anyway, now it is just a matter of logics :P
- Corrected some minor bugs in step forward.
- Step forward is now rather messy, but still better than
  four hours ago.. altough this can be hard to believe.
- Added some wizards that help finding bugs.
- Rewritten dyn process get_state as it was guilty of
  premature optimization :)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@825 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-06 01:47:02 +00:00
matrevis efe7dedd61 - Request queues are now correctly managed by the ConcreteEnvironment
copy constructor and by the add_resource and remove_resource methods
  found in ConcreteHistory.
- Scheduler now adds the requests in the queue when appropriate, and
  removes them when exhausted.
- Still to implement the management of the state of requests depending
  on their position in the queue
- Still to implement the way threads block depending on the state of
  their requests
- step_forward now reuses some bunch of code taken from the prototype


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@824 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-05 17:09:45 +00:00
tchernobog 132db18b8c - Split between abstract base class (sgpem::CairoWidget) and
derived widget
- Add History::set_notify_enabled() for usage by the frontend 
(for example, when loading from file, you'll want to call
set_notify_enabled(false) before starting)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@823 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-04 20:08:55 +00:00
tchernobog 2174c25f74 - Fix drawing of widget background. Now I'll move the code to
an abstract base class, and I'll start working out the 
adjustement / resizing problems (they're not easy to work out 
correctly).


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@822 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-04 19:12:17 +00:00
elvez 974702af3e - Added other two dialogs for the gui
- Added exception specifications to the methods of the serializer interface and xml plugin

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@821 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-04 00:29:37 +00:00
matrevis 56d7ddbc5a - Widgets now will be shown. Still some problem with their background
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@820 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-03 15:43:21 +00:00
tchernobog b76756c2a8 - Add untested code to SchedulableWidget, manually inheriting from a raw Gtk::Widget
and doing things by hand


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@819 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-03 11:16:16 +00:00
elvez 82289edc14 - Corrected a potentially disastrous automatic int->uint conversion in TextSimulation
- Make test-history run by commenting some "dangerous" lines
- Added a couple of comments to SchedulablesWidget::update() in the hope the may be useful to others in finding where the bug resides...

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@818 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-03 01:34:49 +00:00
matrevis 9f4415a835 - Sorry, I forgot to remove a debug printf statement.
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@817 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-03 00:42:28 +00:00
matrevis 96055b4cf1 - minor bugfix: scheduler was terminating subrequests before decreasing
their elapsed time
- requests are now behaving nicely, since they are raised at the correct
  instant, and terminated at the right instant
- the ready queues are still not ready, tough :(, anyway, now there is
  really nothing else to do before them.
- stepforward is looking much more uglier (if possible).


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@816 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-03 00:30:36 +00:00
elvez 10091d7a16 - Added ResourcePolicyManager
- Removed obsolete files

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@815 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-02 23:38:52 +00:00
matrevis 56a7ce1221 fixed a bug involving scheduler keeping a running thread in the ready queue
when that thread had just been given the cpu.
fixed a bug involving text-simulation displaying the wrong timestamp for
each snaphot. Now the first snapshot printed is correctly tagged "-1".

added (for the sake of lazyness) a method to readyqueue letting anyone
delete the first element on the queue. Not having this would imply
rebuilding the whole queue each time a thread was selected to run.

Small commits avoid complex mergings.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@814 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-02 23:12:32 +00:00
elvez 01490e24ac - Added the ResourcePoliciesGatekeeper class, still not tried to compile it
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@813 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-02 22:21:42 +00:00
tchernobog 43b817aaed - Rename Policy to CPUPolicy where appropriate
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@811 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-02 21:57:36 +00:00
tchernobog 5b577c5979 - Start working on double-buffering on cairo widgets. The system
will SIGSEGV. I will fix this asap, in the meantime use the cmdline
interface.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@810 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-02 13:48:26 +00:00
elvez 6969d5b2c2 - Written what I suppose might be HoltGraph
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@809 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-02 00:28:31 +00:00
elvez b9cbbacd10 - Added ResourcePolicy class. I need to clear some doubts before writing the remaining part of resource policy management...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@808 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-01 22:57:40 +00:00
tchernobog c6ebe792e4 - Make Scheduler::step_forward return a bool representing if
the step went okay or otherwise if the simulation ended
- Fix simulation states in concrete_simulation.cc
- Manage end of input (now CTRL+D exits the program, and 
you can redirect a file in input knowing that at EOF
sgpemv2 will terminate)
- Fix a bug in Scheduler that didn't add the newly created
environment to History when the simulation ended, thus leading
both to a memory leak and an inconsistency in representing
the simulation


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@807 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-08-01 09:19:26 +00:00
matrevis 6f8625d308 Just printing resource name along with ID in subrequest (1 line commit!)
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@806 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-31 23:35:27 +00:00
elvez 504311a390 - Made more clear and complete output from TextSimulation
- Added the "continuous" attribute for the SET and GET commands
- Now resource ids are checked for validity

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@805 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-31 23:18:51 +00:00
elvez 8b20c7d30a - Completed code for visualization of the simulation, there`s still the part for the visualization of the request queue commented
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@800 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-29 15:48:24 +00:00
elvez d64051279f - Fixed bug in copy construction of DynamicProcess
- Fixed bug in get_parameter<bool> in TextSimulation
- Written some new code for visualization of the simulation

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@799 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-29 00:24:48 +00:00
tchernobog 25e5a7319b - Add CairoElements
- Start code for double buffering in custom widgets, using
an off-screen pixmap. Problem: we don't know the height from the 
beginning


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@798 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-28 15:24:56 +00:00
tchernobog 5b22b503a5 - Do the assignment before using the variable...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@797 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-28 12:34:13 +00:00
tchernobog 6c79bc361c - Fix deadlock that blocked PythonPolicy::sort_queue
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@796 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-28 12:21:49 +00:00
tchernobog ebeda15359 - Add DLLEXPORT directive to sgpem::Module
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@795 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-25 11:08:05 +00:00
elvez 6a88e3d85e - Added NullPolicyException to scheduler
- Started code for printing the state of the scheduling
- Fixed a bug in the copy constructor of DynamicThread

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@794 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-23 22:27:33 +00:00
tchernobog f26b80f76b - Keep a map to hold request queues into a concrete_environment
- TODO: fix test-history consequentially (request queues should be prepared
by Scheduler or by Environment?)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@793 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-23 13:38:13 +00:00
elvez 0dd711657f - Added the "set cpu-policy" command. It`s still not useful until we initialize the pyloader plugin...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@789 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-21 13:10:31 +00:00
tchernobog 19ee5c1884 - Fix deletion using an ad-hoc functor to avoid memory leaks, instead that ptr_fun(operator delete). Valgrind says we're doing well with History\!
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@787 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-20 21:50:28 +00:00
tchernobog 69a7ee03eb - Fix visibility support into string_utils
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@786 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-20 11:11:37 +00:00
tchernobog 40180557c7 - Bits and tits of step_forward
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@785 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-20 10:36:24 +00:00
tchernobog dbd24ffd75 - Fix compilation of PoliciesGatekeeper, making sure we don't invalidate iterators
- Fix test-history wrong index variable that made the program try to poke its nose
where it shouldn't


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@783 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-20 08:27:56 +00:00
tchernobog e3d2381212 - Pay attention to iterators invalidated by Container.erase(it) methods.
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@782 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-19 15:50:57 +00:00
tchernobog 95ef5eba53 - Fix compilation of test-python_loader (which doesn't f*ckin' work).
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@781 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-19 14:48:53 +00:00
tchernobog 984d390f3f - Fix typo with iterator initialization (screwed RAII)
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@780 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-19 14:02:44 +00:00
elvez a92b542081 - Completed test-history. I still have some doubts about some points, but I think the current implementation is already a pretty intensive test...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@779 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-18 23:39:33 +00:00
tchernobog 14b5b66b3c - Implement a couple of helper methods into Dynamic(Sub)Request to
make life easier to Scheduler
- Go on implementing a bit more of Scheduler::step_forward()
- Remove "places" from SubRequest


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@778 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-18 15:52:55 +00:00
elvez 53073295d5 - Started test-history
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@777 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-18 14:48:33 +00:00
elvez d9f24de7c0 - Written ConcreteHistory copy constructor
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@775 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-16 21:56:04 +00:00
elvez f4b255d31c - Fixed linking problem with visibility enabled caused by TextSimulation accessing (stupidly) Dynamic* objects
- Removed a bunch of FIXME from text_simulation.cc, now TextSimulation fully cooperates with Environment and History

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@774 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-16 21:43:54 +00:00
elvez a092f3dc7b - Moved Simulation and ConcreteSimulation to the backend
> - Completed ConcreteSimulation, i think it is all we need at the moment...

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@773 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-16 13:35:39 +00:00
paolo cab84a0e3d - deleted "gera ora!" test-global_preferences_serializer.cc
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@772 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 21:03:55 +00:00
elvez 4ab7123ced - Added ConcreteSimulation, but not coded it`s behaviour
- Made Simulation a singleton

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@771 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 17:35:24 +00:00
elvez 1506c46287 - Added the REMOVE command, it was almost completely a cut-and-paste work, so the code will need some refactoring to remove duplicated portions
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@770 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 15:46:13 +00:00
paolo 1ea164cb23 - added a semi-good global preferences serialization test program
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@768 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 11:28:11 +00:00
paolo 2b31d6d2eb - fixed global preferences serialization
- global_preferences.??
- fixed key=value configuration class
  - key_file.??
 


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@767 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 11:25:57 +00:00
paolo 6ea402f012 - removed unused files serializer_visitor.??
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@765 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 01:31:38 +00:00
paolo 35ae7f4eae - updated seriralize_visitor to manage history & environment
- corrected wrong calls to SerializeVisitor in dynamic_process & dynamic_thread



git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@763 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-15 01:25:31 +00:00
elvez d31c31d8a3 - Completed the ADD command, or better, what was implementable of the ADD commmand... Beware this is UNTESTED code!
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@760 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-13 21:09:27 +00:00
elvez 751ecf6415 - Begin writing the ADD command. I`m assuming you all like what I`m doing...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@759 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-13 15:07:15 +00:00
elvez 456cef0fd3 - Added some more templates in preparation of the ADD wizards. This will minimize redundant code in the forthcoming methods
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@758 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-12 23:52:09 +00:00
elvez 4bece17f36 - Completed the SHOW command with the best I can do at the actual stage of development
- Layout of output is not tested so it will surely look odd the first time it is run...

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@757 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-12 22:46:55 +00:00
tchernobog 09268f7fd4 - Add stubs to implement custom widget to show schedulables entities.
Paint a red clown nose just to show the humour of the thing, and that it
works(?).


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@755 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-12 09:24:57 +00:00
tchernobog db34232e72 - Textual simulation is now brought up only if requested
by the -N switch given at the cmdline


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@754 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-12 08:31:25 +00:00
elvez 3612d20ae0 - Partially written the code for the SHOW command.
- Reorganized source to avoid duplicated code

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@753 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-11 22:50:41 +00:00
elvez d4beb67d0e - Added the GET and SET commands to TextSimulation
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@752 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-11 15:46:46 +00:00
elvez 8ffd81b823 - Adjusted copy construction of the Dynamic* hierarchy. Hope this is what you wanted, Matteo...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@751 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-11 14:20:30 +00:00
paolo 864e71b82e - update serializer related files
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@749 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-11 00:04:26 +00:00
elvez 6150af3d30 - Fixed some bugs in command processing, added the configure-cpu-policy command
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@748 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-10 22:28:51 +00:00
elvez 2ede92d6d1 - Written some code for command processing. Still not tested it. Feedback is very much appreciated!
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@746 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-09 16:27:16 +00:00
tchernobog 0e79b163f3 - Fix Dynamic* constructor to add them objects into the correct
vector
- Split push_back in constructors on two lines so the compiler warns
us if returned vectors are temporary objects, or do not match the
expected type


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@745 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-09 15:48:24 +00:00
paolo 301775debd - modified concrete_hystory
- method add_thread - fix push into static_process's vector and
    dynamic_process's vector
  - method add_request - fix push into static_thread's vector and
    dynamic_thread's vetor 


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@744 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-09 15:25:19 +00:00
paolo 4d862a3c2f - added classes needed by serialization
- serializers_gatekeeper
  - serializer
  - serializer_error
  - serializer_visitor (should replace serialize_visitor)



git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@742 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-08 05:50:41 +00:00
tchernobog c1d104dba8 - Small changes: no need to use assert, since libGlade already
does print a warning for us on error
- Fix Makefile


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@740 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-06 12:36:05 +00:00
tchernobog f84c7bbf40 - Do things in a more C++ style
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@739 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-06 12:23:29 +00:00
tchernobog 483cf2815d - Pardon my italian, but "'affanculo" is the only thing that
crosses my mind seeing what was the correct fix.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@738 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-06 11:26:23 +00:00
tchernobog 933d814ddc - Trivialities: change a couple of comments. The SIGSEGV isn't related
to option parsing.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@737 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-06 10:51:37 +00:00
tchernobog 8b1da4e1c7 - Fix plugin.hh visibility attributes
- Improve option parsing
- Strange SIGSEGV still happening (a different one, though)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@736 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-06 09:49:35 +00:00
elvez 3125f3d3cf - Option parsing system is now complete, shame on me, Glib::Option* was so easy to use...
- This is not so important, but the app now segfaults because of this "improvement", don`t say it`s my fault, from what I can understand, glib crashes at some time in between the call to parse_options() is terminated and the call to start_gui() is performed

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@735 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-06 00:05:50 +00:00
elvez b6da06e014 - Added a touch of class to the plugin management system. Now we do things (more or less ;-) ) like gaim does!
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@734 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 21:30:08 +00:00
elvez 27ac53330e - Written what I could for commandline options parsing, it will take a lot to move from this point if I can`t find adequate documentation for the option parsing system of Glib...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@733 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 21:00:57 +00:00
tchernobog 331bf0c9e5 - Empty test-history
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@732 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 17:21:05 +00:00
elvez 45cc6733e4 - Fixed plugin interface. Now both plugins are loaded. Not tried calling the exported functions, though...
- To make sure libraries are not loaded multiple times, only .so files are considered. Beware that this is not portable

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@731 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 17:03:04 +00:00
paolo f181c93527 - added global_preferences_serielizer
- TO DO - test-program not finished



git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@730 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 16:01:44 +00:00
tchernobog d7ca106d89 - Add about dialog as an extra example on how to use libglade with
signals
- Remember that sigc::bind exists for passing extra parameters to
called methods/functions


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@729 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 15:16:58 +00:00
tchernobog 41d20ba6eb - Move to libglademm to handle GUI creation. This is experimental,
but should greatly help in reducing development times


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@727 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 14:37:11 +00:00
tchernobog 1b018234be - Make me compile! (this doesn't necessarily mean it runs, though.)
- Fix SWIG interface to correctly manage things
- PythonPolicyManager isn't a singleton anymore. Since I did this in
a bit of a hurry, check the modifications are right


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@725 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 12:46:12 +00:00
paolo fee643d3f3 - added files to write to and read from configuration files
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@724 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 12:32:16 +00:00
paolo 90fc0c6c95 - addedd files to read/wride configuration files
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@723 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 12:31:07 +00:00
tchernobog cd9a73ee0e - Move macro for checking for GCC visibility support to a separate file
- Delete the "serialize()" method of concrete_environment, since useless


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@721 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-05 11:11:50 +00:00
tchernobog 3e83f4db23 - Fix return type of Scheduler::get_policy() before going to bed
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@718 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 23:12:28 +00:00
tchernobog 22af0b9cdd - Add method to set a request state
- Work on step_forward() a little more
- Add extra check inside dynamic_thread()::decrease_remaining_time()


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@717 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 23:09:10 +00:00
elvez dd4898ca55 - Added SerializeVisitor class and written various serialize() methods
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@716 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 22:34:39 +00:00
tchernobog fcc9e93827 - Let the user disable the new GCC 4.0 visibility support
from configure. This is mainly there for buggy compilers / binutils.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@715 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 22:17:02 +00:00
tchernobog b7d61d5c56 - Fix compilation
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@712 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 19:53:58 +00:00
tchernobog 5ab575dffd - Minor modifications to step_forward()
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@711 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 17:17:31 +00:00
elvez 401c569a9f - Updated interface of pyloader to comply with the new plugin management system`s requirements
- Commented a lot of code to make it compile-able. But still it doesn`t link (at least for me...)

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@710 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 15:05:04 +00:00
tchernobog b65adbe1cc - Empty the main
- Delegate plugin loading to PluginManager so that it can
be tested


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@709 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 11:09:45 +00:00
tchernobog a378239d60 - Only schedule Threads. Ditch support for Policies deciding
if they want to schedule Threads or Processes altogether
- Move setter methods for last_acquisition/last_release from
DynamicSchedulable to DynamicThread
- Rewrite aforesaid methods, along with the respective getter
methods, into Dynamic(Thread|Process)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@708 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 10:46:15 +00:00
tchernobog 736aa25456 - Change pkg-config file to use ${prefix}/include
rather thant ${prefix}/include/sgpemv2: users will
be able to use directives like "#include <sgpemv2/scheduler.hh>"
in their headers, which reduces name clashes.
- Make _mutex a protected member of Singleton, so that
inheriters can recycle it :-)
- Add exclusive access control for step_forward()
- Add two states (future and exhausted) to Request


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@707 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 10:03:43 +00:00
tchernobog 899e20323a - Write some more of Scheduler::step_forward()
- Noted some design lackings, warning the designers


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@706 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 09:30:45 +00:00
tchernobog cb3305c425 - Fix compilation of backend::Module
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@705 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-04 08:27:51 +00:00
elvez 9a7b39ed82 - Completed plugin management system. Now we should start using it...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@703 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 22:01:19 +00:00
tchernobog 9856a86c87 - Start implementing Scheduler::step_forward(). Whoohooo!
- Changed Schedulable::get_remaining_time() in get_elapsed_time()


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@702 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 21:55:09 +00:00
tchernobog 94f7c1d127 - Fix compilation of libbackend.so
- Erased Scheduler::step_forward(): reimplementing from
scratch


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@701 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 20:55:19 +00:00
tchernobog e2fc34f16b - Finish writing ConcreteHistory. That was nasty!
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@700 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 20:10:51 +00:00
tchernobog cb8e8dabc7 - "You got another thing comin'" -- Judas Priest
- Add get_request() method to (Dynamic)SubRequest.
- Implement most of ConcreteHistory. It is a fairly complex class,
with some real evilness in it. It should be thouroughly documented 
ASAP.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@699 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 18:52:50 +00:00
elvez 68b92db976 - Doh! I forgot to add invalid_plugin_exception.cc
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@698 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 18:31:24 +00:00
elvez fac2a08e26 - Written code for plugin management system, some code is missing (Matteo, please...)
- TODO Integrate this new plugin management system into the application

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@697 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-03 18:29:44 +00:00
tchernobog 7d62f4b937 - Mega-update. Take it while it's hot... but my brain's frying!
- Fixed all Dynamic and Static entities lacking proper destructors:
Dynamic entities need to delete Dynamic children, Static entities
need only to delete them from the list of their siblings
- Added methods to get Static "core" from Dynamic*.
- Now get_core() is a pure virtual function into DynamicSchedulable.
A quite nice solution(?), really, if I can say that myself... ;-)
- ConcreteHistory is half-implemented. It's the other half that 
worries me.
- TODO: finish off ConcreteHistory, and check that things get destroyed
properly (no leaks allowed, use valgrind).
- TODO: rework Simulation
- TODO: Scheduler rewrite
- *A side note*: this code is becoming a mess. I prefer references over
pointers, but someone other prefer pointers over references, and what
happens is that you've to continously pass from one to another when
invoking other methods... this is bad.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@694 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 22:20:03 +00:00
tchernobog 787d24964b - Big swing of untested code, all for you verifiers :-)
- Fix ReadyQueue constructor
- Change DynamicSubRequest to take an int as a parameter
- Implement ConcreteEnvironment::get_request_queue() (my word, it's ugly!)
- Please note that it still doesn't compile right: ConcreteHistory
and Scheduler need to be radically changed


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@692 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 17:38:30 +00:00
tchernobog 55c6b23d31 - Fix visibility outside the DSO
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@691 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 15:38:38 +00:00
tchernobog b8f7083bfc - Write interface for History and ConcreteHistory
- Write interface for HistoryObserver
- Remove obsolete interfaces


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@690 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 15:27:30 +00:00
tchernobog 759b90b017 - Substitute the old SchedulableQueue with the new ReadyQueue
- Add interfaces for Process and Thread into the "sgpem.i" SWIG
interface file, change DynamicSchedulable into Schedulable
- Add dynamic_cast for the return value of ReadyQueue::get_item_at()
into the pyloader "sgpem.i" SWIG interface, so that a Schedulable
can be either recognized as a Thread or a Process
- TODO: wrap STL exceptions in SWIG interface
- Please note that code won't compile until the new History and
Scheduler::step_forward() will be in place. This is a known issue.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@689 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 13:51:03 +00:00
tchernobog fa06e2f4f1 - Add operator== methods to dynamic schedulables, and in their interfaces too
- Write class ReadyQueue


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@688 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 12:44:05 +00:00
tchernobog 9da0ef3137 - Fix const methods to return containers of const objects
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@687 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 10:59:46 +00:00
tchernobog 1c72695c2b - Fix return types so that caller can modify the acquired vector
(when appropriate)
- FIXME: see if const std::vector<Something*>& let you invoke
a non-const method of *Something. Else copy these values to
const std::vector<const Something*> before returning.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@686 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 07:30:42 +00:00
matrevis 53da6e4bb8 Vogon Fleet: implementation: Added environment, concrete_environment, a
placeholder for the ready queue, needed by environment, and factorized
stubs for tests in a separate directory. Updated makefile including environment, concrete_environment, ready_queue, but NOT the stubs and/or the tests.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@685 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-07-02 00:52:01 +00:00
tchernobog 36f62cbb8d - Fix compilation error in switch cross-variable initialization
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@677 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-30 22:45:01 +00:00
tchernobog 6b27a8461b - Pretty-indenting code
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@674 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-29 08:44:30 +00:00
tchernobog 7aecc910ba - Me again: still more simplified code for DynamicProcess::get_state().
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@673 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-28 17:09:46 +00:00
tchernobog d7259b8963 - Correct(?) DynamicProcess::get_state()
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@672 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-28 16:55:00 +00:00
elvez a79b4a57d7 - Written DynamicProcess::get_state()
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@670 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-28 15:16:50 +00:00
elvez 628010656e - Updated DynamicSchedulable::operator==
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@667 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-28 09:43:50 +00:00
elvez bfe8f3456e - added FIXME note about deletion of thread objects in DynamicProcess::remove_thread()
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@663 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-25 19:54:36 +00:00
tchernobog 409047a225 - Update plugin interface
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@658 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-24 18:35:43 +00:00
tchernobog 66d46db357 - Separate template definition from template declaration
- Explicitly instantiate Singleton templates to be exported from libbackend.so
- Install only header files that are backend interfaces to be exposed to the user
- Don't use full path for including templates in header files
- Instantiate a couple of smart_ptr templates to have their symbols exported outside the DSO. This happens in history.cc. FIXME: the interface for History will definitely need to be reworked, and the two smart_ptr explicit instantiations removed.
- Change SWIG exported interface to make use of Schedulable instead of (Dynamic|Static)Schedulable
- Fix provided policies to make use of the new interface
- TODO: limit the use of smart_ptrs.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@653 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-23 13:06:39 +00:00
elvez 56db7cd6a2 - Added requests system
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@652 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-22 22:48:33 +00:00
matrevis d8cd3577a7 Arthur Dent: completed test-history, merging with Matteo's.
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@651 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-22 10:47:23 +00:00
elvez e95d915e3a - Added DynamicThread class
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@649 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-21 22:39:35 +00:00
elvez 0a2f37345f - Temporarily disabled template-based singleton system because of a crash virtually surely caused by it
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@648 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-21 20:24:36 +00:00
tchernobog 167f9ad437 - Fix sigsegv when no parameter is passed on the cmdline
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@647 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-21 14:54:59 +00:00
tchernobog 77e61e0b91 - Hide cctors for singletons
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@644 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-21 09:15:41 +00:00
tchernobog 383889a203 - Add unified Singleton support
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@643 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-21 09:09:50 +00:00
elvez 8ca3a61730 - Minor changes to DynamicProcess and DynamicSchedulable to reflect change in design
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@642 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-20 21:49:13 +00:00
elvez ec7c6a7c81 - Added Thread class
- Synchronized DynamicSchedulable and DynamicProcess with changes in design

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@637 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-19 22:37:27 +00:00
elvez 30d070a420 - Added SETPOLICY and LISTPOLICIES commands to text-based interface
- Fixed a bug preventing registration of managers in PoliciesGatekeeper

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@634 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-15 20:07:03 +00:00
elvez 9642918dd8 - Added StaticThread and DynamicProcess classes
- Added Process interface
- Classes are still incomplete

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@632 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-14 23:31:31 +00:00
elvez a1662de194 - Added the Schedulable interface
- Renamed SchedulableStatus to DynamicSchedulable
- Implemented almost all methods of DynamicSchedulable

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@630 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-13 16:37:57 +00:00
elvez dd6085a0a6 - Renamed Process to StaticProcess
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@627 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-13 14:20:05 +00:00
elvez 1f7972c308 - Renamed Schedulable to StaticSchedulable
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@626 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-13 13:55:47 +00:00
elvez c381ee8875 - Doh! I forgot to svn move two files...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@622 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-12 14:08:00 +00:00
elvez 1706119e4d - Renamed GlobalSettings to GlobalPreferences
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@621 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-12 14:04:06 +00:00
elvez 65ed285807 - Implemented PythonPolicyManager::collect_policies()
- Integrated PythonPolicyManager with PoliciesGatekeeper

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@620 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-12 13:16:10 +00:00
elvez c5d78f3547 - updated PoliciesGatekeeper to reflect change in design, it is still not usable at this time
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@616 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-10 15:44:42 +00:00
elvez 1e75fe91f1 - Added Policy::wants() and updated related code. Scheduler::get_ready_queue() still always returns a process queue...
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@615 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-09 16:51:53 +00:00
elvez e5b90a39ad - Added PoliciesGatekeeper class, but still not integrated it with the rest of the code
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@610 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-06 22:13:33 +00:00
elvez da39407173 - removed Scheduler-initiated events
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@604 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-03 15:51:38 +00:00
elvez 8062dd95da - Completed renaming of class SchedulableList to SchedulableQueue
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@603 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-03 15:19:13 +00:00
elvez 4508ed017b -changing SchedulableList to SchedulableQueue: intermediate commit,
so SVN can let me use "mv"

git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@602 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-06-03 14:40:19 +00:00
tchernobog 51f0d7fbe7 - Merged branch 0.3-r556--SPLIT_PYLOADER_CONFIG back into trunk
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@561 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-04-06 19:01:13 +00:00
tchernobog 9dc21270a2 - Make GUI a little bit more responsive. Still doesn't scroll
to the end of output
- Use GraphicalTerminalIO::read_command into GraphicalTerminalIO::onSend()
as per specs (fixes a program crash)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@552 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-18 10:50:16 +00:00
tchernobog 8102eb8b7e - Finish fix for return values in PythonPolicy
- Put mutex and global _ret_val variable into 
ScriptAdapter instead of the global space, space which is
anyway not accessible after decref'ing the corresponding 
python module


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@527 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-10 15:21:44 +00:00
tchernobog 3b593e00ae - Partial attempt at fixing PythonPolicies broken return values
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@525 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-10 14:54:24 +00:00
tchernobog c3065a86c6 - Fix bug with retval not treated as a bool value in wait_unlock()
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@523 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-10 11:38:10 +00:00
tchernobog ec3361cb84 - Make test-python_loader a unit test instead of an integration test
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@520 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-09 22:20:55 +00:00
tchernobog ef733b37e8 - Update test-python_loader, do not link to libpyloader anymore
- TODO: sigsegv (due to an hidden vtable?)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@519 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-09 21:56:16 +00:00
matrevis bb1d465b34 - ArthurDent - Test completato codice del test di history
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@517 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-09 16:25:21 +00:00
tchernobog 0c2cba8bbe - Fix compilation of test-history
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@515 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-09 11:37:09 +00:00
tchernobog 92e6f3be2b - Add copyright notices to existing builtin python policies
- Implement system to dinamically pass plugins and policies search paths to
the sgpemv2 binary and tests (class GlobalSettings)
- Drastically reduce usage of hardcoded paths in code except as 
default overridable values


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@514 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-09 10:49:41 +00:00
matrevis 24a0194368 - added some test drafts
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@512 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-09 05:19:43 +00:00
matrevis 8afcc2edbb - Added draft of test code for Frontend Unit testing
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@510 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-08 16:57:23 +00:00
tchernobog 6a0bf4f444 - Give facelift to test_loader. Still to be finished.
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@509 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-08 16:47:39 +00:00
tchernobog 1388eeeac1 - Add extended support for casting between different types
of smart_ptr


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@507 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-08 12:49:14 +00:00
tchernobog e0142149b0 - Update smartp to version 1.1: add support for dynamic casting
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@501 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-07 01:27:15 +00:00
tchernobog 7207f697c7 - Fix obscure bug (with reference initialization, or nested name
specifiers?)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@490 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-05 01:07:51 +00:00
tchernobog 8dab5cc548 - Remove non-const method from Python-exported interface that allowed
to change a SchedulableStatus from a user Policy


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@488 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-04 13:46:08 +00:00
tchernobog 17678ebbe4 - Reorganize makefile to install files in a reorganized directory
hierarchy: 
	- make room for future plugins
	- separate real plugins from their satellite helper
	data


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@484 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-03-03 21:04:42 +00:00
tchernobog 0a6b34d6ab - Catch UserInterruptException launched from
PythonPolicy in Scheduler, but it cheerfully 
segfaults python...


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@464 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-26 23:38:25 +00:00
tchernobog 8c39173c2f - Update ac_python_devel macro to integrate advice from Horst
- Improve a little GraphicalTerminalIo


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@461 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-25 19:32:54 +00:00
tchernobog d5565b319f - Add placeholder for a plugin interface to implement.
Will need to be finished with next milestones.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@460 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-25 12:40:24 +00:00
tchernobog c6dcf32fa2 - Remove all leftover references to DummyPolicy
- Adjust installation of backend header files, so users
can write their own plugins (needs to be documented)


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@459 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-25 12:31:46 +00:00
tchernobog 56534edb6c - Make libpyloader a loadable plugin (warning: won't work
on Window$ unless you change the string "libpyloader" to
"pyloader" into main.cc)
- Fix Makefile to support module creation and loading
- 2DO: 
	- Add a class into backend to load and manage plugins
	- Install plugins into separate directory
	- Remove hardcoded paths


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@458 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-25 12:21:30 +00:00
fpaparel 4833658cc1 - added doxygen documentation
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@446 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 15:10:36 +00:00
tchernobog ed389f8b37 updated graphical_simulation.hh - Djina
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@440 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 14:25:48 +00:00
matrevis 5034c59728 - Added documentation to some headers
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@438 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 13:19:27 +00:00
johnny 52857f08b9 - More documentation
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@437 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 12:22:25 +00:00
tchernobog 7ce8cf93c3 - Add SJF
- Re-enable FCFS sorting function
- Correct bug in PythonPolicy that wronged return value
of is_pre_emptible()


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@435 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 11:17:37 +00:00
tchernobog 5dddd9b488 - I don't remember exactly what I did.
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@434 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 10:39:40 +00:00
tchernobog 6446c205ea - Fix trivial conflict between revisions
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@433 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 10:07:47 +00:00
tchernobog edd8cc3e95 - Print arrival time instead of priority for Schedulables
at this stage of development


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@432 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 09:53:23 +00:00
tchernobog 1395347b1a - Fix Schedulable::get_name() in SWIG export interface
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@431 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 09:02:32 +00:00
tchernobog dc84bfd16c - Return numeric_limits<int>::max() from get_time_slice()
of PythonPolicy when the Python user-implemented one returns
a negative value


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@430 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 08:28:18 +00:00
jinx 924896ca0b Added some comments to the source code
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@422 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 01:33:06 +00:00
johnny 47c184ac3f - "Commenting The Source(tm)" 02-2006 - The best summer camp of the world - Second part
- Reorganized the .cc files to match the .hh methods order.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@421 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 01:24:21 +00:00
paolo 02e69f9214 Documented history.hh, policy.hh, policy_manager.hh, slice.hh - ps
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@419 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-24 01:06:49 +00:00
tchernobog 3a38a2d3a6 - Add comment about a thing to fix ;-)
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@418 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 22:54:27 +00:00
tchernobog c91a86a9ca - Move compiled test to the ``testsuite'' subdir
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@415 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 22:02:59 +00:00
tchernobog dfe1593b44 - Tadaaaan! Fixed it! Now:
- SWIG generate interface doesn't do a mess with namespaces anymore
  - Improved PythonPolicy to be acceptably faster
  - FCFS implemented, sir!
  - FIXME : the qsort implementation doesn't seem right


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@413 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 21:50:43 +00:00
elvez 876fb85614 - Fixed a couple of problems in doc
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@412 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 20:59:56 +00:00
elvez 24edbf1c43 - Commented file
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@411 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 19:32:09 +00:00
tchernobog da5fc9d195 git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@410 3ecf2c5c-341e-0410-92b4-d18e462d057c 2006-02-23 19:08:30 +00:00
tchernobog cd9b1b1892 - Fix typos
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@409 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 19:02:21 +00:00
tchernobog e2211907f5 - Add documentation for classes:
- (C++) PythonPolicyManager
  - (Python) Policy, ScriptAdapter, fcfs


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@408 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 18:55:14 +00:00
elvez 9091035003 - Commented file
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@407 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 18:09:33 +00:00
elvez 34fba3517a - Commented file
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@406 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 18:01:00 +00:00
johnny 1d326590ee - "Commenting The Source(tm)" 02-2006 - The best summer camp of the world - First part
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@405 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 17:59:02 +00:00
elvez cf01cd6611 - Commented file
git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@404 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 17:19:20 +00:00
tchernobog c996eca3ba - Add yet-not-functional code for managing the "return" keypress
in the input entrybox


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@398 3ecf2c5c-341e-0410-92b4-d18e462d057c
2006-02-23 12:50:19 +00:00