scheduling

OpenMP Dynamic vs Guided Scheduling

╄→гoц情女王★ 提交于 2019-12-02 17:13:18
I'm studying OpenMP's scheduling and specifically the different types. I understand the general behavior of each type, but clarification would be helpful regarding when to choose between dynamic and guided scheduling. Intel's docs describe dynamic scheduling: Use the internal work queue to give a chunk-sized block of loop iterations to each thread. When a thread is finished, it retrieves the next block of loop iterations from the top of the work queue. By default, the chunk size is 1. Be careful when using this scheduling type because of the extra overhead involved. It also describes guided

When are lock free data structures less performant than mutual exclusion (mutexes)?

孤者浪人 提交于 2019-12-02 16:23:52
I read somewhere (can't find the page anymore) that lock free data structures are more efficient "for certain workloads" which seems to imply that sometimes they're actually slower or the gain from them can be zero in some situations. Taking the ~100 cycle hit of a lock instruction to do an atomic op sounds plenty faster to me than going to sleep and waiting for the scheduler to wake the process back up, so it's not obvious to me under what circumstances a lock free data structure would be less preferable than old fashioned mutexes. If the lock is available 99% of the time and the process

Optimized algorithm to schedule tasks with dependency?

你。 提交于 2019-12-02 16:19:16
There are tasks that read from a file, do some processing and write to a file. These tasks are to be scheduled based on the dependency. Also tasks can be run in parallel, so the algorithm needs to be optimized to run dependent tasks in serial and as much as possible in parallel. eg: A -> B A -> C B -> D E -> F So one way to run this would be run 1, 2 & 4 in parallel. Followed by 3. Another way could be run 1 and then run 2, 3 & 4 in parallel. Another could be run 1 and 3 in serial, 2 and 4 in parallel. Any ideas? Let each task (e.g. A,B,... ) be nodes in a directed acyclic graph and define the

how to shield a cpu from the linux scheduler (prevent it scheduling threads onto that cpu)?

不打扰是莪最后的温柔 提交于 2019-12-02 14:31:44
It is possible to use sched_setaffinity to pin a thread to a cpu, increasing performance (in some situations) From the linux man page: Restricting a process to run on a single CPU also avoids the performance cost caused by the cache invalidation that occurs when a process ceases to execute on one CPU and then recommences execution on a different CPU Further, if I desire a more real-time response, I can change the scheduler policy for that thread to SCHED_FIFO , and up the priority to some high value (up to sched_get_priority_max ), meaning the thread in question should always pre-empt any

Teacher time schedule algorithm

安稳与你 提交于 2019-12-02 14:10:41
This is a problem I've had on my mind for a long time. Being the son of a teacher and a programmer, it occurred to me early on... but I still haven't found a solution for it. So this is the problem. One needs to create a time schedule for a school, using some constraints. These are generally divided in two categories: Sanity Checks A teacher cannot teach two classes at the same time A student cannot follow two lessons at the same time Some teachers must have at least one day off during the week All the days of the week should be covered by the time table Subject X must have exactly so-and-so

DAG(directed acyclic graph) dynamic job scheduler

无人久伴 提交于 2019-12-02 14:08:46
I need to manage a large workflow of ETL tasks, which execution depends on time, data availability or an external event. Some jobs may fail during execution of the workflow and the system should have the ability to restart a failed workflow branch without waiting for whole workflow to finish execution. Are there any frameworks in python that can handle this? I see several core functions: DAG bulding Execution of nodes (run shell cmd with wait,logging etc.) Ability to rebuild sub-graph in parent DAG during execution Ability to manual execute nodes or sub-graph while parent graph is running

How to setup Quartz.NET for scheduling Emails

旧巷老猫 提交于 2019-12-02 11:35:40
问题 There are two solutions Quartz.server.2008.sln and quartz.2008.sln in the downloaded quartz.NET library. Now I have to setup recurring job. There would be table in the database where all schedules will be defined (like first friday of the month, each 5 in month, each sunday 12 am...etc). I have the method executed on schedule. Now how can i use quartz.net to get schedule from database and set the method to execute? what are the proper steps? 回答1: I think you can create a windows service

Schedule timer to be executed once a month - C#

让人想犯罪 __ 提交于 2019-12-02 10:42:36
I need to transfer some data from SQL Server to MySQL, once a month. I have already done this transfer stuff, but I don't know (and I have not found out on the internet) how to set a timer that executes this transfer a specific day every month. I don't want just to set a timer interval in milliseconds because the number of days vary from one month to another. Any help is appreciated... You could use the Windows Task Scheduler for this kind of work. Look here for command line options of Schtasks (there's tons of them) Example 1: To schedule a task that runs on the first day of every month The

Scheduling a time in the future to send an email in Java or Python

こ雲淡風輕ζ 提交于 2019-12-02 07:16:36
I'm writing an application and I'd like it to somehow schedule an email to be sent at a later date (likely an hour after it is run). The programming language will be Python or Java. Any open-source tools available for that purpose? EDIT: I forgot to mention it's to be run after a test run, so the application will already be down and I believe the Quartz solution wouldn't work. Would this be possible? Ideally, I'd like to hear that SMTP protocol has some hidden stuff that allows this, and would just require adding some flag to the message and email providers would interpret as to having to send

How to setup Quartz.NET for scheduling Emails

让人想犯罪 __ 提交于 2019-12-02 07:15:06
There are two solutions Quartz.server.2008.sln and quartz.2008.sln in the downloaded quartz.NET library. Now I have to setup recurring job. There would be table in the database where all schedules will be defined (like first friday of the month, each 5 in month, each sunday 12 am...etc). I have the method executed on schedule. Now how can i use quartz.net to get schedule from database and set the method to execute? what are the proper steps? danyolgiax I think you can create a windows service running in background. You can read the scheduleFromDatabase varaible from database and then pass it